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

Side by Side Diff: src/x64/codegen-x64.h

Issue 2053003: Refactor the fast-case code for loading local/global variables and... (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: '' Created 10 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « src/ia32/codegen-ia32.cc ('k') | src/x64/codegen-x64.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2010 the V8 project authors. All rights reserved. 1 // Copyright 2010 the V8 project authors. All rights reserved.
2 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
(...skipping 417 matching lines...) Expand 10 before | Expand all | Expand 10 after
428 // temporarily while the code generator is being transformed. 428 // temporarily while the code generator is being transformed.
429 void LoadAndSpill(Expression* expression); 429 void LoadAndSpill(Expression* expression);
430 430
431 // Read a value from a slot and leave it on top of the expression stack. 431 // Read a value from a slot and leave it on top of the expression stack.
432 void LoadFromSlot(Slot* slot, TypeofState typeof_state); 432 void LoadFromSlot(Slot* slot, TypeofState typeof_state);
433 void LoadFromSlotCheckForArguments(Slot* slot, TypeofState state); 433 void LoadFromSlotCheckForArguments(Slot* slot, TypeofState state);
434 Result LoadFromGlobalSlotCheckExtensions(Slot* slot, 434 Result LoadFromGlobalSlotCheckExtensions(Slot* slot,
435 TypeofState typeof_state, 435 TypeofState typeof_state,
436 JumpTarget* slow); 436 JumpTarget* slow);
437 437
438 // Support for loading from local/global variables and arguments
439 // whose location is known unless they are shadowed by
440 // eval-introduced bindings. Generates no code for unsupported slot
441 // types and therefore expects to fall through to the slow jump target.
442 void EmitDynamicLoadFromSlotFastCase(Slot* slot,
443 TypeofState typeof_state,
444 Result* result,
445 JumpTarget* slow,
446 JumpTarget* done);
447
438 // Store the value on top of the expression stack into a slot, leaving the 448 // Store the value on top of the expression stack into a slot, leaving the
439 // value in place. 449 // value in place.
440 void StoreToSlot(Slot* slot, InitState init_state); 450 void StoreToSlot(Slot* slot, InitState init_state);
441 451
442 // Load a property of an object, returning it in a Result. 452 // Load a property of an object, returning it in a Result.
443 // The object and the property name are passed on the stack, and 453 // The object and the property name are passed on the stack, and
444 // not changed. 454 // not changed.
445 Result EmitKeyedLoad(bool is_global); 455 Result EmitKeyedLoad(bool is_global);
446 456
447 // Special code for typeof expressions: Unfortunately, we must 457 // Special code for typeof expressions: Unfortunately, we must
(...skipping 595 matching lines...) Expand 10 before | Expand all | Expand 10 after
1043 return ObjectBits::encode(object_.code()) | 1053 return ObjectBits::encode(object_.code()) |
1044 AddressBits::encode(addr_.code()) | 1054 AddressBits::encode(addr_.code()) |
1045 ScratchBits::encode(scratch_.code()); 1055 ScratchBits::encode(scratch_.code());
1046 } 1056 }
1047 }; 1057 };
1048 1058
1049 1059
1050 } } // namespace v8::internal 1060 } } // namespace v8::internal
1051 1061
1052 #endif // V8_X64_CODEGEN_X64_H_ 1062 #endif // V8_X64_CODEGEN_X64_H_
OLDNEW
« no previous file with comments | « src/ia32/codegen-ia32.cc ('k') | src/x64/codegen-x64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698