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

Side by Side Diff: src/objects-inl.h

Issue 327173002: Optimize various forms of slice.call(arguments, ...) (Closed) Base URL: https://github.com/v8/v8.git@master
Patch Set: Created 6 years, 6 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
« no previous file with comments | « src/objects.h ('k') | src/runtime.h » ('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 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 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 // Review notes: 5 // Review notes:
6 // 6 //
7 // - The use of macros in these inline functions may seem superfluous 7 // - The use of macros in these inline functions may seem superfluous
8 // but it is absolutely needed to make sure gcc generates optimal 8 // but it is absolutely needed to make sure gcc generates optimal
9 // code. gcc is not happy when attempting to inline too deep. 9 // code. gcc is not happy when attempting to inline too deep.
10 // 10 //
(...skipping 5326 matching lines...) Expand 10 before | Expand all | Expand 10 after
5337 profiler_ticks, 5337 profiler_ticks,
5338 kProfilerTicksOffset) 5338 kProfilerTicksOffset)
5339 5339
5340 #endif 5340 #endif
5341 5341
5342 5342
5343 BOOL_GETTER(SharedFunctionInfo, 5343 BOOL_GETTER(SharedFunctionInfo,
5344 compiler_hints, 5344 compiler_hints,
5345 optimization_disabled, 5345 optimization_disabled,
5346 kOptimizationDisabled) 5346 kOptimizationDisabled)
5347 BOOL_GETTER(SharedFunctionInfo,
5348 compiler_hints,
5349 optimistic_optimizations,
5350 kOptimisticOptimizations)
5351
5352
5353 bool SharedFunctionInfo::use_optimistic_optimizations() {
5354 return BooleanBit::get(compiler_hints(), kOptimisticOptimizations)
5355 ? false : true;
5356 }
5357
5358
5359 void SharedFunctionInfo::disable_optimistic_optimizations() {
5360 set_compiler_hints(BooleanBit::set(compiler_hints(),
5361 kOptimisticOptimizations,
5362 true));
5363 }
5347 5364
5348 5365
5349 void SharedFunctionInfo::set_optimization_disabled(bool disable) { 5366 void SharedFunctionInfo::set_optimization_disabled(bool disable) {
5350 set_compiler_hints(BooleanBit::set(compiler_hints(), 5367 set_compiler_hints(BooleanBit::set(compiler_hints(),
5351 kOptimizationDisabled, 5368 kOptimizationDisabled,
5352 disable)); 5369 disable));
5353 // If disabling optimizations we reflect that in the code object so 5370 // If disabling optimizations we reflect that in the code object so
5354 // it will not be counted as optimizable code. 5371 // it will not be counted as optimizable code.
5355 if ((code()->kind() == Code::FUNCTION) && disable) { 5372 if ((code()->kind() == Code::FUNCTION) && disable) {
5356 code()->set_optimizable(false); 5373 code()->set_optimizable(false);
(...skipping 1628 matching lines...) Expand 10 before | Expand all | Expand 10 after
6985 #undef READ_SHORT_FIELD 7002 #undef READ_SHORT_FIELD
6986 #undef WRITE_SHORT_FIELD 7003 #undef WRITE_SHORT_FIELD
6987 #undef READ_BYTE_FIELD 7004 #undef READ_BYTE_FIELD
6988 #undef WRITE_BYTE_FIELD 7005 #undef WRITE_BYTE_FIELD
6989 #undef NOBARRIER_READ_BYTE_FIELD 7006 #undef NOBARRIER_READ_BYTE_FIELD
6990 #undef NOBARRIER_WRITE_BYTE_FIELD 7007 #undef NOBARRIER_WRITE_BYTE_FIELD
6991 7008
6992 } } // namespace v8::internal 7009 } } // namespace v8::internal
6993 7010
6994 #endif // V8_OBJECTS_INL_H_ 7011 #endif // V8_OBJECTS_INL_H_
OLDNEW
« no previous file with comments | « src/objects.h ('k') | src/runtime.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698