Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(178)

Issue 200095: Add near calls (32-bit displacement) to Code objects on X64 platform. (Closed)

Created:
11 years, 3 months ago by William Hesse
Modified:
9 years, 7 months ago
CC:
v8-dev
Visibility:
Public.

Description

Add near calls (32-bit displacement) to Code objects on X64 platform. Committed: http://code.google.com/p/v8/source/detail?r=3021

Patch Set 1 #

Patch Set 2 : '' #

Patch Set 3 : '' #

Patch Set 4 : '' #

Total comments: 10

Patch Set 5 : '' #

Patch Set 6 : '' #

Patch Set 7 : '' #

Patch Set 8 : '' #

Unified diffs Side-by-side diffs Delta from patch set Stats (+169 lines, -73 lines) Patch
M src/arm/assembler-arm-inl.h View 1 2 3 4 5 6 1 chunk +7 lines, -1 line 0 comments Download
M src/assembler.h View 1 2 3 4 5 6 1 chunk +1 line, -0 lines 0 comments Download
M src/ia32/assembler-ia32-inl.h View 1 2 3 4 5 6 1 chunk +9 lines, -3 lines 0 comments Download
M src/mark-compact.cc View 3 4 5 6 2 chunks +8 lines, -2 lines 0 comments Download
M src/memory.h View 1 2 3 4 5 6 1 chunk +4 lines, -0 lines 0 comments Download
M src/objects.cc View 1 2 3 4 5 6 1 chunk +3 lines, -2 lines 0 comments Download
M src/serialize.cc View 4 5 6 7 6 chunks +21 lines, -6 lines 0 comments Download
M src/x64/assembler-x64.h View 1 2 3 4 5 6 7 chunks +23 lines, -18 lines 0 comments Download
M src/x64/assembler-x64.cc View 1 2 3 4 5 6 5 chunks +36 lines, -3 lines 0 comments Download
M src/x64/assembler-x64-inl.h View 1 2 3 4 5 6 5 chunks +52 lines, -13 lines 0 comments Download
M src/x64/macro-assembler-x64.cc View 1 2 3 4 5 6 4 chunks +5 lines, -25 lines 0 comments Download

Messages

Total messages: 3 (0 generated)
William Hesse
Please review. Erik just needs to review (de)serialization.
11 years, 3 months ago (2009-09-23 12:39:27 UTC) #1
Erik Corry
That part of it looks good to me. http://codereview.chromium.org/200095/diff/10001/10012 File src/serialize.cc (right): http://codereview.chromium.org/200095/diff/10001/10012#newcode940 Line 940: ...
11 years, 3 months ago (2009-09-24 08:36:42 UTC) #2
Lasse Reichstein
11 years, 3 months ago (2009-09-24 10:37:20 UTC) #3
LGTM if it works (I don't have complete understanding of how the relocation
works).

http://codereview.chromium.org/200095/diff/10001/10010
File src/arm/assembler-arm-inl.h (right):

http://codereview.chromium.org/200095/diff/10001/10010#newcode84
Line 84: return Memory::Object_at(Assembler::target_address_address_at(pc_));
Can't we find a better name than "address_address"?

http://codereview.chromium.org/200095/diff/10001/10012
File src/serialize.cc (right):

http://codereview.chromium.org/200095/diff/10001/10012#newcode943
Line 943: intptr_t int_target = reinterpret_cast<intptr_t>(encoded_target);
int_target is a bad name for something that isn't an int.
How about "scalar_target", or "target_as_scalar", or just "intptr_target".

http://codereview.chromium.org/200095/diff/10001/10012#newcode944
Line 944: int_target = (int_target & 0xFFFFFFFFU) |
(Memory::uint64_at(rinfo->pc() + 4) << 32);
This needs a comment!
I.e., I have no idea what is going on.

Can't you get rid of the uint64_at thing in 32-bit mode?

http://codereview.chromium.org/200095/diff/10001/10012#newcode1670
Line 1670: encoded = reinterpret_cast<Address>(0xFFFFFFFFU &
reinterpret_cast<intptr_t>(encoded));
The content of "encoded" isn't really an Address (it's not a pointer to a byte
in memory if it's always at most 32 bit). Maybe it should have a different type.

http://codereview.chromium.org/200095/diff/10001/10008
File src/x64/assembler-x64-inl.h (right):

http://codereview.chromium.org/200095/diff/10001/10008#newcode284
Line 284: pc_ + Assembler::kRealPatchReturnSequenceAddressOffset);
"Real" is not a good prefix for a variable. It doesn't explain how
kPatchReturnSequenceAddressOffset isn't real.

http://codereview.chromium.org/200095/diff/10001/10006
File src/x64/assembler-x64.cc (right):

http://codereview.chromium.org/200095/diff/10001/10006#newcode267
Line 267: Assembler::Assembler(void* buffer, int buffer_size):
Move ":" to next line or initializer to this line.

http://codereview.chromium.org/200095/diff/10001/10007
File src/x64/assembler-x64.h (right):

http://codereview.chromium.org/200095/diff/10001/10007#newcode940
Line 940: void jmp(Handle<Code> target, RelocInfo::Mode rmode);
On a side note, I would like to move all Handle operations to the
Macro-assembler, so that the assembler doesn't need to know about the domain
model. I.e., all handle and smi operations should be in the macro assembler, and
reduce to assembler operations on simple values.

Powered by Google App Engine
This is Rietveld 408576698