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

Side by Side Diff: src/a64/macro-assembler-a64.h

Issue 141713009: A64: Port LSeqStringSetChar optimizations from r16707 and r17521. (Closed) Base URL: https://v8.googlecode.com/svn/branches/experimental/a64
Patch Set: Use enum instead of bool Created 6 years, 10 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/a64/lithium-codegen-a64.cc ('k') | src/a64/macro-assembler-a64.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 2013 the V8 project authors. All rights reserved. 1 // Copyright 2013 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 56 matching lines...) Expand 10 before | Expand all | Expand 10 after
67 enum SmiCheck { INLINE_SMI_CHECK, OMIT_SMI_CHECK }; 67 enum SmiCheck { INLINE_SMI_CHECK, OMIT_SMI_CHECK };
68 enum LinkRegisterStatus { kLRHasNotBeenSaved, kLRHasBeenSaved }; 68 enum LinkRegisterStatus { kLRHasNotBeenSaved, kLRHasBeenSaved };
69 enum TargetAddressStorageMode { 69 enum TargetAddressStorageMode {
70 CAN_INLINE_TARGET_ADDRESS, 70 CAN_INLINE_TARGET_ADDRESS,
71 NEVER_INLINE_TARGET_ADDRESS 71 NEVER_INLINE_TARGET_ADDRESS
72 }; 72 };
73 enum UntagMode { kNotSpeculativeUntag, kSpeculativeUntag }; 73 enum UntagMode { kNotSpeculativeUntag, kSpeculativeUntag };
74 enum ArrayHasHoles { kArrayCantHaveHoles, kArrayCanHaveHoles }; 74 enum ArrayHasHoles { kArrayCantHaveHoles, kArrayCanHaveHoles };
75 enum CopyHint { kCopyUnknown, kCopyShort, kCopyLong }; 75 enum CopyHint { kCopyUnknown, kCopyShort, kCopyLong };
76 enum DiscardMoveMode { kDontDiscardForSameWReg, kDiscardForSameWReg }; 76 enum DiscardMoveMode { kDontDiscardForSameWReg, kDiscardForSameWReg };
77 enum SeqStringSetCharCheckIndexType { kIndexIsSmi, kIndexIsInteger32 };
77 78
78 class MacroAssembler : public Assembler { 79 class MacroAssembler : public Assembler {
79 public: 80 public:
80 MacroAssembler(Isolate* isolate, byte * buffer, unsigned buffer_size); 81 MacroAssembler(Isolate* isolate, byte * buffer, unsigned buffer_size);
81 82
82 inline Handle<Object> CodeObject(); 83 inline Handle<Object> CodeObject();
83 84
84 // Instruction set functions ------------------------------------------------ 85 // Instruction set functions ------------------------------------------------
85 // Logical macros. 86 // Logical macros.
86 inline void And(const Register& rd, 87 inline void And(const Register& rd,
(...skipping 1381 matching lines...) Expand 10 before | Expand all | Expand 10 after
1468 // Picks out an array index from the hash field. 1469 // Picks out an array index from the hash field.
1469 // Register use: 1470 // Register use:
1470 // hash - holds the index's hash. Clobbered. 1471 // hash - holds the index's hash. Clobbered.
1471 // index - holds the overwritten index on exit. 1472 // index - holds the overwritten index on exit.
1472 void IndexFromHash(Register hash, Register index); 1473 void IndexFromHash(Register hash, Register index);
1473 1474
1474 // --------------------------------------------------------------------------- 1475 // ---------------------------------------------------------------------------
1475 // Inline caching support. 1476 // Inline caching support.
1476 1477
1477 void EmitSeqStringSetCharCheck(Register string, 1478 void EmitSeqStringSetCharCheck(Register string,
1478 Register index, // Smi 1479 Register index,
1480 SeqStringSetCharCheckIndexType index_type,
1481 Register scratch,
1479 uint32_t encoding_mask); 1482 uint32_t encoding_mask);
1480 1483
1481 // Generate code for checking access rights - used for security checks 1484 // Generate code for checking access rights - used for security checks
1482 // on access to global objects across environments. The holder register 1485 // on access to global objects across environments. The holder register
1483 // is left untouched, whereas both scratch registers are clobbered. 1486 // is left untouched, whereas both scratch registers are clobbered.
1484 void CheckAccessGlobalProxy(Register holder_reg, 1487 void CheckAccessGlobalProxy(Register holder_reg,
1485 Register scratch, 1488 Register scratch,
1486 Label* miss); 1489 Label* miss);
1487 1490
1488 // Hash the interger value in 'key' register. 1491 // Hash the interger value in 'key' register.
(...skipping 708 matching lines...) Expand 10 before | Expand all | Expand 10 after
2197 #error "Unsupported option" 2200 #error "Unsupported option"
2198 #define CODE_COVERAGE_STRINGIFY(x) #x 2201 #define CODE_COVERAGE_STRINGIFY(x) #x
2199 #define CODE_COVERAGE_TOSTRING(x) CODE_COVERAGE_STRINGIFY(x) 2202 #define CODE_COVERAGE_TOSTRING(x) CODE_COVERAGE_STRINGIFY(x)
2200 #define __FILE_LINE__ __FILE__ ":" CODE_COVERAGE_TOSTRING(__LINE__) 2203 #define __FILE_LINE__ __FILE__ ":" CODE_COVERAGE_TOSTRING(__LINE__)
2201 #define ACCESS_MASM(masm) masm->stop(__FILE_LINE__); masm-> 2204 #define ACCESS_MASM(masm) masm->stop(__FILE_LINE__); masm->
2202 #else 2205 #else
2203 #define ACCESS_MASM(masm) masm-> 2206 #define ACCESS_MASM(masm) masm->
2204 #endif 2207 #endif
2205 2208
2206 #endif // V8_A64_MACRO_ASSEMBLER_A64_H_ 2209 #endif // V8_A64_MACRO_ASSEMBLER_A64_H_
OLDNEW
« no previous file with comments | « src/a64/lithium-codegen-a64.cc ('k') | src/a64/macro-assembler-a64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698