Mercurial > hg > graal-compiler
annotate graal/com.oracle.graal.hotspot.sparc/src/com/oracle/graal/hotspot/sparc/SPARCDeoptimizeOp.java @ 15456:bb97b75d1d65
AMD64: implemented DeoptimizationStub.deoptimizationHandler
author | twisti |
---|---|
date | Wed, 30 Apr 2014 15:41:44 -1000 |
parents | ed29f7ff71eb |
children | 8fc336a04d77 |
rev | line source |
---|---|
10871
c3b09d69dfde
SPARC: fixes and more implementation; can now allocate objects
twisti
parents:
diff
changeset
|
1 /* |
c3b09d69dfde
SPARC: fixes and more implementation; can now allocate objects
twisti
parents:
diff
changeset
|
2 * Copyright (c) 2012, 2013, Oracle and/or its affiliates. All rights reserved. |
c3b09d69dfde
SPARC: fixes and more implementation; can now allocate objects
twisti
parents:
diff
changeset
|
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
c3b09d69dfde
SPARC: fixes and more implementation; can now allocate objects
twisti
parents:
diff
changeset
|
4 * |
c3b09d69dfde
SPARC: fixes and more implementation; can now allocate objects
twisti
parents:
diff
changeset
|
5 * This code is free software; you can redistribute it and/or modify it |
c3b09d69dfde
SPARC: fixes and more implementation; can now allocate objects
twisti
parents:
diff
changeset
|
6 * under the terms of the GNU General Public License version 2 only, as |
c3b09d69dfde
SPARC: fixes and more implementation; can now allocate objects
twisti
parents:
diff
changeset
|
7 * published by the Free Software Foundation. |
c3b09d69dfde
SPARC: fixes and more implementation; can now allocate objects
twisti
parents:
diff
changeset
|
8 * |
c3b09d69dfde
SPARC: fixes and more implementation; can now allocate objects
twisti
parents:
diff
changeset
|
9 * This code is distributed in the hope that it will be useful, but WITHOUT |
c3b09d69dfde
SPARC: fixes and more implementation; can now allocate objects
twisti
parents:
diff
changeset
|
10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or |
c3b09d69dfde
SPARC: fixes and more implementation; can now allocate objects
twisti
parents:
diff
changeset
|
11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License |
c3b09d69dfde
SPARC: fixes and more implementation; can now allocate objects
twisti
parents:
diff
changeset
|
12 * version 2 for more details (a copy is included in the LICENSE file that |
c3b09d69dfde
SPARC: fixes and more implementation; can now allocate objects
twisti
parents:
diff
changeset
|
13 * accompanied this code). |
c3b09d69dfde
SPARC: fixes and more implementation; can now allocate objects
twisti
parents:
diff
changeset
|
14 * |
c3b09d69dfde
SPARC: fixes and more implementation; can now allocate objects
twisti
parents:
diff
changeset
|
15 * You should have received a copy of the GNU General Public License version |
c3b09d69dfde
SPARC: fixes and more implementation; can now allocate objects
twisti
parents:
diff
changeset
|
16 * 2 along with this work; if not, write to the Free Software Foundation, |
c3b09d69dfde
SPARC: fixes and more implementation; can now allocate objects
twisti
parents:
diff
changeset
|
17 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. |
c3b09d69dfde
SPARC: fixes and more implementation; can now allocate objects
twisti
parents:
diff
changeset
|
18 * |
c3b09d69dfde
SPARC: fixes and more implementation; can now allocate objects
twisti
parents:
diff
changeset
|
19 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA |
c3b09d69dfde
SPARC: fixes and more implementation; can now allocate objects
twisti
parents:
diff
changeset
|
20 * or visit www.oracle.com if you need additional information or have any |
c3b09d69dfde
SPARC: fixes and more implementation; can now allocate objects
twisti
parents:
diff
changeset
|
21 * questions. |
c3b09d69dfde
SPARC: fixes and more implementation; can now allocate objects
twisti
parents:
diff
changeset
|
22 */ |
c3b09d69dfde
SPARC: fixes and more implementation; can now allocate objects
twisti
parents:
diff
changeset
|
23 package com.oracle.graal.hotspot.sparc; |
c3b09d69dfde
SPARC: fixes and more implementation; can now allocate objects
twisti
parents:
diff
changeset
|
24 |
15456
bb97b75d1d65
AMD64: implemented DeoptimizationStub.deoptimizationHandler
twisti
parents:
15104
diff
changeset
|
25 import static com.oracle.graal.hotspot.HotSpotHostBackend.*; |
10871
c3b09d69dfde
SPARC: fixes and more implementation; can now allocate objects
twisti
parents:
diff
changeset
|
26 |
c3b09d69dfde
SPARC: fixes and more implementation; can now allocate objects
twisti
parents:
diff
changeset
|
27 import com.oracle.graal.asm.sparc.*; |
c3b09d69dfde
SPARC: fixes and more implementation; can now allocate objects
twisti
parents:
diff
changeset
|
28 import com.oracle.graal.lir.*; |
14991
64dcb92ee75a
Truffle: Change signature for Truffle calls from (PackedFrame, Arguments) to (Object[]).
Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
parents:
14013
diff
changeset
|
29 import com.oracle.graal.lir.StandardOp.BlockEndOp; |
11832
97d6932a309b
CodeCacheProvider.encodeDeoptActionAndReason now returns a Constant
Gilles Duboscq <duboscq@ssw.jku.at>
parents:
10871
diff
changeset
|
30 import com.oracle.graal.lir.asm.*; |
10871
c3b09d69dfde
SPARC: fixes and more implementation; can now allocate objects
twisti
parents:
diff
changeset
|
31 import com.oracle.graal.lir.sparc.*; |
c3b09d69dfde
SPARC: fixes and more implementation; can now allocate objects
twisti
parents:
diff
changeset
|
32 |
c3b09d69dfde
SPARC: fixes and more implementation; can now allocate objects
twisti
parents:
diff
changeset
|
33 @Opcode("DEOPT") |
14013 | 34 final class SPARCDeoptimizeOp extends SPARCLIRInstruction implements BlockEndOp { |
10871
c3b09d69dfde
SPARC: fixes and more implementation; can now allocate objects
twisti
parents:
diff
changeset
|
35 |
c3b09d69dfde
SPARC: fixes and more implementation; can now allocate objects
twisti
parents:
diff
changeset
|
36 @State private LIRFrameState info; |
c3b09d69dfde
SPARC: fixes and more implementation; can now allocate objects
twisti
parents:
diff
changeset
|
37 |
11832
97d6932a309b
CodeCacheProvider.encodeDeoptActionAndReason now returns a Constant
Gilles Duboscq <duboscq@ssw.jku.at>
parents:
10871
diff
changeset
|
38 SPARCDeoptimizeOp(LIRFrameState info) { |
10871
c3b09d69dfde
SPARC: fixes and more implementation; can now allocate objects
twisti
parents:
diff
changeset
|
39 this.info = info; |
c3b09d69dfde
SPARC: fixes and more implementation; can now allocate objects
twisti
parents:
diff
changeset
|
40 } |
c3b09d69dfde
SPARC: fixes and more implementation; can now allocate objects
twisti
parents:
diff
changeset
|
41 |
c3b09d69dfde
SPARC: fixes and more implementation; can now allocate objects
twisti
parents:
diff
changeset
|
42 @Override |
13227
1a66453f73db
renamed TargetMethodAssembler to CompilationResultBuilder
Doug Simon <doug.simon@oracle.com>
parents:
12503
diff
changeset
|
43 public void emitCode(CompilationResultBuilder crb, SPARCMacroAssembler masm) { |
10871
c3b09d69dfde
SPARC: fixes and more implementation; can now allocate objects
twisti
parents:
diff
changeset
|
44 // TODO the patched call address looks odd (and is invalid) compared to other runtime calls: |
12503
d7f8dd4fe876
minor reformatting based on 'mx eclipseformat'
Doug Simon <doug.simon@oracle.com>
parents:
12363
diff
changeset
|
45 // 0xffffffff749bb5fc: call 0xffffffff415a720c ; {runtime_call} |
d7f8dd4fe876
minor reformatting based on 'mx eclipseformat'
Doug Simon <doug.simon@oracle.com>
parents:
12363
diff
changeset
|
46 // [Exception Handler] |
d7f8dd4fe876
minor reformatting based on 'mx eclipseformat'
Doug Simon <doug.simon@oracle.com>
parents:
12363
diff
changeset
|
47 // 0xffffffff749bb604: call 0xffffffff749bb220 ; {runtime_call} |
d7f8dd4fe876
minor reformatting based on 'mx eclipseformat'
Doug Simon <doug.simon@oracle.com>
parents:
12363
diff
changeset
|
48 // 0xffffffff749bb608: nop |
d7f8dd4fe876
minor reformatting based on 'mx eclipseformat'
Doug Simon <doug.simon@oracle.com>
parents:
12363
diff
changeset
|
49 // [Deopt Handler Code] |
d7f8dd4fe876
minor reformatting based on 'mx eclipseformat'
Doug Simon <doug.simon@oracle.com>
parents:
12363
diff
changeset
|
50 // 0xffffffff749bb60c: call 0xffffffff748da540 ; {runtime_call} |
d7f8dd4fe876
minor reformatting based on 'mx eclipseformat'
Doug Simon <doug.simon@oracle.com>
parents:
12363
diff
changeset
|
51 // 0xffffffff749bb610: nop |
15104 | 52 SPARCCall.directCall(crb, masm, crb.foreignCalls.lookupForeignCall(UNCOMMON_TRAP_HANDLER), null, false, info); |
10871
c3b09d69dfde
SPARC: fixes and more implementation; can now allocate objects
twisti
parents:
diff
changeset
|
53 } |
c3b09d69dfde
SPARC: fixes and more implementation; can now allocate objects
twisti
parents:
diff
changeset
|
54 } |