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

Side by Side Diff: src/x64/full-codegen-x64.cc

Issue 139903005: We shouldn't throw under FLAG_debug_code, rather abort. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: REBASE + mjsunit.status todo update. 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/mips/macro-assembler-mips.cc ('k') | src/x64/macro-assembler-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 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 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 3374 matching lines...) Expand 10 before | Expand all | Expand 10 after
3385 Register index = rbx; 3385 Register index = rbx;
3386 Register value = rcx; 3386 Register value = rcx;
3387 3387
3388 VisitForStackValue(args->at(1)); // index 3388 VisitForStackValue(args->at(1)); // index
3389 VisitForStackValue(args->at(2)); // value 3389 VisitForStackValue(args->at(2)); // value
3390 VisitForAccumulatorValue(args->at(0)); // string 3390 VisitForAccumulatorValue(args->at(0)); // string
3391 __ pop(value); 3391 __ pop(value);
3392 __ pop(index); 3392 __ pop(index);
3393 3393
3394 if (FLAG_debug_code) { 3394 if (FLAG_debug_code) {
3395 __ ThrowIf(NegateCondition(__ CheckSmi(value)), kNonSmiValue); 3395 __ Check(__ CheckSmi(value), kNonSmiValue);
3396 __ ThrowIf(NegateCondition(__ CheckSmi(index)), kNonSmiValue); 3396 __ Check(__ CheckSmi(index), kNonSmiValue);
3397 } 3397 }
3398 3398
3399 __ SmiToInteger32(value, value); 3399 __ SmiToInteger32(value, value);
3400 __ SmiToInteger32(index, index); 3400 __ SmiToInteger32(index, index);
3401 3401
3402 if (FLAG_debug_code) { 3402 if (FLAG_debug_code) {
3403 static const uint32_t one_byte_seq_type = kSeqStringTag | kOneByteStringTag; 3403 static const uint32_t one_byte_seq_type = kSeqStringTag | kOneByteStringTag;
3404 __ EmitSeqStringSetCharCheck(string, index, value, one_byte_seq_type); 3404 __ EmitSeqStringSetCharCheck(string, index, value, one_byte_seq_type);
3405 } 3405 }
3406 3406
(...skipping 11 matching lines...) Expand all
3418 Register index = rbx; 3418 Register index = rbx;
3419 Register value = rcx; 3419 Register value = rcx;
3420 3420
3421 VisitForStackValue(args->at(1)); // index 3421 VisitForStackValue(args->at(1)); // index
3422 VisitForStackValue(args->at(2)); // value 3422 VisitForStackValue(args->at(2)); // value
3423 VisitForAccumulatorValue(args->at(0)); // string 3423 VisitForAccumulatorValue(args->at(0)); // string
3424 __ pop(value); 3424 __ pop(value);
3425 __ pop(index); 3425 __ pop(index);
3426 3426
3427 if (FLAG_debug_code) { 3427 if (FLAG_debug_code) {
3428 __ ThrowIf(NegateCondition(__ CheckSmi(value)), kNonSmiValue); 3428 __ Check(__ CheckSmi(value), kNonSmiValue);
3429 __ ThrowIf(NegateCondition(__ CheckSmi(index)), kNonSmiValue); 3429 __ Check(__ CheckSmi(index), kNonSmiValue);
3430 } 3430 }
3431 3431
3432 __ SmiToInteger32(value, value); 3432 __ SmiToInteger32(value, value);
3433 __ SmiToInteger32(index, index); 3433 __ SmiToInteger32(index, index);
3434 3434
3435 if (FLAG_debug_code) { 3435 if (FLAG_debug_code) {
3436 static const uint32_t two_byte_seq_type = kSeqStringTag | kTwoByteStringTag; 3436 static const uint32_t two_byte_seq_type = kSeqStringTag | kTwoByteStringTag;
3437 __ EmitSeqStringSetCharCheck(string, index, value, two_byte_seq_type); 3437 __ EmitSeqStringSetCharCheck(string, index, value, two_byte_seq_type);
3438 } 3438 }
3439 3439
(...skipping 1453 matching lines...) Expand 10 before | Expand all | Expand 10 after
4893 4893
4894 ASSERT_EQ(isolate->builtins()->OsrAfterStackCheck()->entry(), 4894 ASSERT_EQ(isolate->builtins()->OsrAfterStackCheck()->entry(),
4895 Assembler::target_address_at(call_target_address)); 4895 Assembler::target_address_at(call_target_address));
4896 return OSR_AFTER_STACK_CHECK; 4896 return OSR_AFTER_STACK_CHECK;
4897 } 4897 }
4898 4898
4899 4899
4900 } } // namespace v8::internal 4900 } } // namespace v8::internal
4901 4901
4902 #endif // V8_TARGET_ARCH_X64 4902 #endif // V8_TARGET_ARCH_X64
OLDNEW
« no previous file with comments | « src/mips/macro-assembler-mips.cc ('k') | src/x64/macro-assembler-x64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698