Mercurial > hg > graal-compiler
annotate src/os_cpu/linux_x86/vm/assembler_linux_x86.cpp @ 1621:6027dddc26c6
6677629: PhaseIterGVN::subsume_node() should call hash_delete() and add_users_to_worklist()
Summary: Use replace_node() method instead of subsume_node().
Reviewed-by: jrose, never
author | kvn |
---|---|
date | Mon, 28 Jun 2010 14:54:39 -0700 |
parents | c18cbe5936b8 |
children | f95d63e2154a |
rev | line source |
---|---|
0 | 1 /* |
1552
c18cbe5936b8
6941466: Oracle rebranding changes for Hotspot repositories
trims
parents:
304
diff
changeset
|
2 * Copyright (c) 1999, 2008, Oracle and/or its affiliates. All rights reserved. |
0 | 3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
4 * | |
5 * This code is free software; you can redistribute it and/or modify it | |
6 * under the terms of the GNU General Public License version 2 only, as | |
7 * published by the Free Software Foundation. | |
8 * | |
9 * This code is distributed in the hope that it will be useful, but WITHOUT | |
10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or | |
11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License | |
12 * version 2 for more details (a copy is included in the LICENSE file that | |
13 * accompanied this code). | |
14 * | |
15 * You should have received a copy of the GNU General Public License version | |
16 * 2 along with this work; if not, write to the Free Software Foundation, | |
17 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. | |
18 * | |
1552
c18cbe5936b8
6941466: Oracle rebranding changes for Hotspot repositories
trims
parents:
304
diff
changeset
|
19 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA |
c18cbe5936b8
6941466: Oracle rebranding changes for Hotspot repositories
trims
parents:
304
diff
changeset
|
20 * or visit www.oracle.com if you need additional information or have any |
c18cbe5936b8
6941466: Oracle rebranding changes for Hotspot repositories
trims
parents:
304
diff
changeset
|
21 * questions. |
0 | 22 * |
23 */ | |
24 | |
25 #include "incls/_precompiled.incl" | |
304 | 26 #include "incls/_assembler_linux_x86.cpp.incl" |
0 | 27 |
304 | 28 #ifndef _LP64 |
0 | 29 void MacroAssembler::int3() { |
30 call(RuntimeAddress(CAST_FROM_FN_PTR(address, os::breakpoint))); | |
31 } | |
32 | |
33 void MacroAssembler::get_thread(Register thread) { | |
34 movl(thread, rsp); | |
35 shrl(thread, PAGE_SHIFT); | |
36 | |
37 ExternalAddress tls_base((address)ThreadLocalStorage::sp_map_addr()); | |
38 Address index(noreg, thread, Address::times_4); | |
39 ArrayAddress tls(tls_base, index); | |
40 | |
41 movptr(thread, tls); | |
42 } | |
304 | 43 #else |
44 void MacroAssembler::int3() { | |
45 call(RuntimeAddress(CAST_FROM_FN_PTR(address, os::breakpoint))); | |
46 } | |
47 | |
48 void MacroAssembler::get_thread(Register thread) { | |
49 // call pthread_getspecific | |
50 // void * pthread_getspecific(pthread_key_t key); | |
51 if (thread != rax) { | |
52 push(rax); | |
53 } | |
54 push(rdi); | |
55 push(rsi); | |
56 push(rdx); | |
57 push(rcx); | |
58 push(r8); | |
59 push(r9); | |
60 push(r10); | |
61 // XXX | |
62 mov(r10, rsp); | |
63 andq(rsp, -16); | |
64 push(r10); | |
65 push(r11); | |
66 | |
67 movl(rdi, ThreadLocalStorage::thread_index()); | |
68 call(RuntimeAddress(CAST_FROM_FN_PTR(address, pthread_getspecific))); | |
69 | |
70 pop(r11); | |
71 pop(rsp); | |
72 pop(r10); | |
73 pop(r9); | |
74 pop(r8); | |
75 pop(rcx); | |
76 pop(rdx); | |
77 pop(rsi); | |
78 pop(rdi); | |
79 if (thread != rax) { | |
80 mov(thread, rax); | |
81 pop(rax); | |
82 } | |
83 } | |
84 #endif |