Chromium Code Reviews

Side by Side Diff: src/builtins.h

Issue 1617503003: [Atomics] code stubs for atomic operations (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: more cleanup Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View unified diff |
OLDNEW
1 // Copyright 2011 the V8 project authors. All rights reserved. 1 // Copyright 2011 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef V8_BUILTINS_H_ 5 #ifndef V8_BUILTINS_H_
6 #define V8_BUILTINS_H_ 6 #define V8_BUILTINS_H_
7 7
8 #include "src/base/flags.h" 8 #include "src/base/flags.h"
9 #include "src/handles.h" 9 #include "src/handles.h"
10 10
(...skipping 288 matching lines...)
299 V(OnStackReplacement, BUILTIN, UNINITIALIZED, kNoExtraICState) \ 299 V(OnStackReplacement, BUILTIN, UNINITIALIZED, kNoExtraICState) \
300 V(InterruptCheck, BUILTIN, UNINITIALIZED, kNoExtraICState) \ 300 V(InterruptCheck, BUILTIN, UNINITIALIZED, kNoExtraICState) \
301 V(StackCheck, BUILTIN, UNINITIALIZED, kNoExtraICState) \ 301 V(StackCheck, BUILTIN, UNINITIALIZED, kNoExtraICState) \
302 \ 302 \
303 V(MarkCodeAsToBeExecutedOnce, BUILTIN, UNINITIALIZED, kNoExtraICState) \ 303 V(MarkCodeAsToBeExecutedOnce, BUILTIN, UNINITIALIZED, kNoExtraICState) \
304 V(MarkCodeAsExecutedOnce, BUILTIN, UNINITIALIZED, kNoExtraICState) \ 304 V(MarkCodeAsExecutedOnce, BUILTIN, UNINITIALIZED, kNoExtraICState) \
305 V(MarkCodeAsExecutedTwice, BUILTIN, UNINITIALIZED, kNoExtraICState) \ 305 V(MarkCodeAsExecutedTwice, BUILTIN, UNINITIALIZED, kNoExtraICState) \
306 CODE_AGE_LIST_WITH_ARG(DECLARE_CODE_AGE_BUILTIN, V) 306 CODE_AGE_LIST_WITH_ARG(DECLARE_CODE_AGE_BUILTIN, V)
307 307
308 // Define list of builtins implemented in TurboFan (with JS linkage). 308 // Define list of builtins implemented in TurboFan (with JS linkage).
309 #define BUILTIN_LIST_T(V) \ 309 #define BUILTIN_LIST_T(V) \
310 V(MathCeil, 2) \ 310 V(MathCeil, 2) \
311 V(MathClz32, 2) \ 311 V(MathClz32, 2) \
312 V(MathFloor, 2) \ 312 V(MathFloor, 2) \
313 V(MathRound, 2) \ 313 V(MathRound, 2) \
314 V(MathSqrt, 2) \ 314 V(MathSqrt, 2) \
315 V(MathTrunc, 2) \ 315 V(MathTrunc, 2) \
316 V(ObjectHasOwnProperty, 2) 316 V(ObjectHasOwnProperty, 2) \
317 V(AtomicsLoadCheck, 3)
317 318
318 // Define list of builtin handlers implemented in assembly. 319 // Define list of builtin handlers implemented in assembly.
319 #define BUILTIN_LIST_H(V) \ 320 #define BUILTIN_LIST_H(V) \
320 V(LoadIC_Slow, LOAD_IC) \ 321 V(LoadIC_Slow, LOAD_IC) \
321 V(KeyedLoadIC_Slow, KEYED_LOAD_IC) \ 322 V(KeyedLoadIC_Slow, KEYED_LOAD_IC) \
322 V(StoreIC_Slow, STORE_IC) \ 323 V(StoreIC_Slow, STORE_IC) \
323 V(KeyedStoreIC_Slow, KEYED_STORE_IC) \ 324 V(KeyedStoreIC_Slow, KEYED_STORE_IC) \
324 V(LoadIC_Normal, LOAD_IC) \ 325 V(LoadIC_Normal, LOAD_IC) \
325 V(StoreIC_Normal, STORE_IC) 326 V(StoreIC_Normal, STORE_IC)
326 327
(...skipping 319 matching lines...)
646 MacroAssembler* masm); \ 647 MacroAssembler* masm); \
647 static void Generate_Make##C##CodeYoungAgainOddMarking( \ 648 static void Generate_Make##C##CodeYoungAgainOddMarking( \
648 MacroAssembler* masm); 649 MacroAssembler* masm);
649 CODE_AGE_LIST(DECLARE_CODE_AGE_BUILTIN_GENERATOR) 650 CODE_AGE_LIST(DECLARE_CODE_AGE_BUILTIN_GENERATOR)
650 #undef DECLARE_CODE_AGE_BUILTIN_GENERATOR 651 #undef DECLARE_CODE_AGE_BUILTIN_GENERATOR
651 652
652 static void Generate_MarkCodeAsToBeExecutedOnce(MacroAssembler* masm); 653 static void Generate_MarkCodeAsToBeExecutedOnce(MacroAssembler* masm);
653 static void Generate_MarkCodeAsExecutedOnce(MacroAssembler* masm); 654 static void Generate_MarkCodeAsExecutedOnce(MacroAssembler* masm);
654 static void Generate_MarkCodeAsExecutedTwice(MacroAssembler* masm); 655 static void Generate_MarkCodeAsExecutedTwice(MacroAssembler* masm);
655 656
657 static void Generate_AtomicsLoadCheck(compiler::CodeStubAssembler* assembler);
658
656 static void InitBuiltinFunctionTable(); 659 static void InitBuiltinFunctionTable();
657 660
658 bool initialized_; 661 bool initialized_;
659 662
660 friend class BuiltinFunctionTable; 663 friend class BuiltinFunctionTable;
661 friend class Isolate; 664 friend class Isolate;
662 665
663 DISALLOW_COPY_AND_ASSIGN(Builtins); 666 DISALLOW_COPY_AND_ASSIGN(Builtins);
664 }; 667 };
665 668
666 } // namespace internal 669 } // namespace internal
667 } // namespace v8 670 } // namespace v8
668 671
669 #endif // V8_BUILTINS_H_ 672 #endif // V8_BUILTINS_H_
OLDNEW

Powered by Google App Engine