X87: Unify JSEntryStub and JSConstructEntryStub, and some more code stub cleanups.

port r23742.

original commit message:

  Unify JSEntryStub and JSConstructEntryStub, and some more code stub cleanups.

BUG=
R=weiliang.lin@intel.com

Review URL: https://codereview.chromium.org/557233002

Patch from Jing Bao <jing.bao@intel.com>.

git-svn-id: https://v8.googlecode.com/svn/branches/bleeding_edge@23821 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
This commit is contained in:
weiliang.lin@intel.com 2014-09-10 07:17:23 +00:00
parent 4f5b0911db
commit d79d1f782f
2 changed files with 5 additions and 7 deletions

View File

@ -2073,7 +2073,7 @@ void CEntryStub::Generate(MacroAssembler* masm) {
}
void JSEntryStub::GenerateBody(MacroAssembler* masm, bool is_construct) {
void JSEntryStub::Generate(MacroAssembler* masm) {
Label invoke, handler_entry, exit;
Label not_outermost_js, not_outermost_js_2;
@ -2084,7 +2084,7 @@ void JSEntryStub::GenerateBody(MacroAssembler* masm, bool is_construct) {
__ mov(ebp, esp);
// Push marker in two places.
int marker = is_construct ? StackFrame::ENTRY_CONSTRUCT : StackFrame::ENTRY;
int marker = type();
__ push(Immediate(Smi::FromInt(marker))); // context slot
__ push(Immediate(Smi::FromInt(marker))); // function slot
// Save callee-saved registers (C calling conventions).
@ -2135,7 +2135,7 @@ void JSEntryStub::GenerateBody(MacroAssembler* masm, bool is_construct) {
// pop the faked function when we return. Notice that we cannot store a
// reference to the trampoline code directly in this stub, because the
// builtin stubs may not have been generated yet.
if (is_construct) {
if (type() == StackFrame::ENTRY_CONSTRUCT) {
ExternalReference construct_entry(Builtins::kJSConstructEntryTrampoline,
isolate());
__ mov(edx, Immediate(construct_entry));

View File

@ -66,8 +66,6 @@ class NameDictionaryLookupStub: public PlatformCodeStub {
IndexBits::encode(index.code()) | LookupModeBits::encode(mode);
}
void Generate(MacroAssembler* masm);
static void GenerateNegativeLookup(MacroAssembler* masm,
Label* miss,
Label* done,
@ -116,7 +114,7 @@ class NameDictionaryLookupStub: public PlatformCodeStub {
class IndexBits: public BitField<int, 6, 3> {};
class LookupModeBits: public BitField<LookupMode, 9, 1> {};
DEFINE_CODE_STUB(NameDictionaryLookup, PlatformCodeStub);
DEFINE_PLATFORM_CODE_STUB(NameDictionaryLookup, PlatformCodeStub);
};
@ -324,7 +322,7 @@ class RecordWriteStub: public PlatformCodeStub {
virtual inline Major MajorKey() const FINAL OVERRIDE { return RecordWrite; }
void Generate(MacroAssembler* masm);
virtual void Generate(MacroAssembler* masm) OVERRIDE;
void GenerateIncremental(MacroAssembler* masm, Mode mode);
void CheckNeedsToInformIncrementalMarker(
MacroAssembler* masm,