OLD | NEW |
1 // Copyright 2011 the V8 project authors. All rights reserved. | 1 // Copyright 2011 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 1009 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1020 } | 1020 } |
1021 | 1021 |
1022 | 1022 |
1023 LInstruction* LChunkBuilder::DoApplyArguments(HApplyArguments* instr) { | 1023 LInstruction* LChunkBuilder::DoApplyArguments(HApplyArguments* instr) { |
1024 Abort("Unimplemented: %s", "DoApplyArguments"); | 1024 Abort("Unimplemented: %s", "DoApplyArguments"); |
1025 return NULL; | 1025 return NULL; |
1026 } | 1026 } |
1027 | 1027 |
1028 | 1028 |
1029 LInstruction* LChunkBuilder::DoPushArgument(HPushArgument* instr) { | 1029 LInstruction* LChunkBuilder::DoPushArgument(HPushArgument* instr) { |
1030 ++argument_count_; | 1030 Abort("Unimplemented: %s", "DoPushArgument"); |
1031 LOperand* argument = UseOrConstant(instr->argument()); | 1031 return NULL; |
1032 return new LPushArgument(argument); | |
1033 } | 1032 } |
1034 | 1033 |
1035 | 1034 |
1036 LInstruction* LChunkBuilder::DoGlobalObject(HGlobalObject* instr) { | 1035 LInstruction* LChunkBuilder::DoGlobalObject(HGlobalObject* instr) { |
1037 return DefineAsRegister(new LGlobalObject); | 1036 return DefineAsRegister(new LGlobalObject); |
1038 } | 1037 } |
1039 | 1038 |
1040 | 1039 |
1041 LInstruction* LChunkBuilder::DoGlobalReceiver(HGlobalReceiver* instr) { | 1040 LInstruction* LChunkBuilder::DoGlobalReceiver(HGlobalReceiver* instr) { |
1042 Abort("Unimplemented: %s", "DoGlobalReceiver"); | 1041 Abort("Unimplemented: %s", "DoGlobalReceiver"); |
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1075 } | 1074 } |
1076 | 1075 |
1077 | 1076 |
1078 LInstruction* LChunkBuilder::DoCallKnownGlobal(HCallKnownGlobal* instr) { | 1077 LInstruction* LChunkBuilder::DoCallKnownGlobal(HCallKnownGlobal* instr) { |
1079 Abort("Unimplemented: %s", "DoCallKnownGlobal"); | 1078 Abort("Unimplemented: %s", "DoCallKnownGlobal"); |
1080 return NULL; | 1079 return NULL; |
1081 } | 1080 } |
1082 | 1081 |
1083 | 1082 |
1084 LInstruction* LChunkBuilder::DoCallNew(HCallNew* instr) { | 1083 LInstruction* LChunkBuilder::DoCallNew(HCallNew* instr) { |
1085 LOperand* constructor = UseFixed(instr->constructor(), rdi); | 1084 Abort("Unimplemented: %s", "DoCallNew"); |
1086 argument_count_ -= instr->argument_count(); | 1085 return NULL; |
1087 LCallNew* result = new LCallNew(constructor); | |
1088 return MarkAsCall(DefineFixed(result, rax), instr); | |
1089 } | 1086 } |
1090 | 1087 |
1091 | 1088 |
1092 LInstruction* LChunkBuilder::DoCallFunction(HCallFunction* instr) { | 1089 LInstruction* LChunkBuilder::DoCallFunction(HCallFunction* instr) { |
1093 Abort("Unimplemented: %s", "DoCallFunction"); | 1090 Abort("Unimplemented: %s", "DoCallFunction"); |
1094 return NULL; | 1091 return NULL; |
1095 } | 1092 } |
1096 | 1093 |
1097 | 1094 |
1098 LInstruction* LChunkBuilder::DoCallRuntime(HCallRuntime* instr) { | 1095 LInstruction* LChunkBuilder::DoCallRuntime(HCallRuntime* instr) { |
(...skipping 275 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1374 ASSERT(to.IsDouble()); | 1371 ASSERT(to.IsDouble()); |
1375 return DefineAsRegister(new LInteger32ToDouble(Use(instr->value()))); | 1372 return DefineAsRegister(new LInteger32ToDouble(Use(instr->value()))); |
1376 } | 1373 } |
1377 } | 1374 } |
1378 UNREACHABLE(); | 1375 UNREACHABLE(); |
1379 return NULL; | 1376 return NULL; |
1380 } | 1377 } |
1381 | 1378 |
1382 | 1379 |
1383 LInstruction* LChunkBuilder::DoCheckNonSmi(HCheckNonSmi* instr) { | 1380 LInstruction* LChunkBuilder::DoCheckNonSmi(HCheckNonSmi* instr) { |
1384 LOperand* value = UseRegisterAtStart(instr->value()); | 1381 Abort("Unimplemented: %s", "DoCheckNonSmi"); |
1385 return AssignEnvironment(new LCheckSmi(value, zero)); | 1382 return NULL; |
1386 } | 1383 } |
1387 | 1384 |
1388 | 1385 |
1389 LInstruction* LChunkBuilder::DoCheckInstanceType(HCheckInstanceType* instr) { | 1386 LInstruction* LChunkBuilder::DoCheckInstanceType(HCheckInstanceType* instr) { |
1390 Abort("Unimplemented: %s", "DoCheckInstanceType"); | 1387 Abort("Unimplemented: %s", "DoCheckInstanceType"); |
1391 return NULL; | 1388 return NULL; |
1392 } | 1389 } |
1393 | 1390 |
1394 | 1391 |
1395 LInstruction* LChunkBuilder::DoCheckPrototypeMaps(HCheckPrototypeMaps* instr) { | 1392 LInstruction* LChunkBuilder::DoCheckPrototypeMaps(HCheckPrototypeMaps* instr) { |
1396 Abort("Unimplemented: %s", "DoCheckPrototypeMaps"); | 1393 Abort("Unimplemented: %s", "DoCheckPrototypeMaps"); |
1397 return NULL; | 1394 return NULL; |
1398 } | 1395 } |
1399 | 1396 |
1400 | 1397 |
1401 LInstruction* LChunkBuilder::DoCheckSmi(HCheckSmi* instr) { | 1398 LInstruction* LChunkBuilder::DoCheckSmi(HCheckSmi* instr) { |
1402 LOperand* value = UseRegisterAtStart(instr->value()); | 1399 Abort("Unimplemented: %s", "DoCheckSmi"); |
1403 return AssignEnvironment(new LCheckSmi(value, not_zero)); | 1400 return NULL; |
1404 } | 1401 } |
1405 | 1402 |
1406 | 1403 |
1407 LInstruction* LChunkBuilder::DoCheckFunction(HCheckFunction* instr) { | 1404 LInstruction* LChunkBuilder::DoCheckFunction(HCheckFunction* instr) { |
1408 Abort("Unimplemented: %s", "DoCheckFunction"); | 1405 Abort("Unimplemented: %s", "DoCheckFunction"); |
1409 return NULL; | 1406 return NULL; |
1410 } | 1407 } |
1411 | 1408 |
1412 | 1409 |
1413 LInstruction* LChunkBuilder::DoCheckMap(HCheckMap* instr) { | 1410 LInstruction* LChunkBuilder::DoCheckMap(HCheckMap* instr) { |
1414 LOperand* value = UseRegisterAtStart(instr->value()); | 1411 Abort("Unimplemented: %s", "DoCheckMap"); |
1415 LCheckMap* result = new LCheckMap(value); | 1412 return NULL; |
1416 return AssignEnvironment(result); | |
1417 } | 1413 } |
1418 | 1414 |
1419 | 1415 |
1420 LInstruction* LChunkBuilder::DoReturn(HReturn* instr) { | 1416 LInstruction* LChunkBuilder::DoReturn(HReturn* instr) { |
1421 return new LReturn(UseFixed(instr->value(), rax)); | 1417 return new LReturn(UseFixed(instr->value(), rax)); |
1422 } | 1418 } |
1423 | 1419 |
1424 | 1420 |
1425 LInstruction* LChunkBuilder::DoConstant(HConstant* instr) { | 1421 LInstruction* LChunkBuilder::DoConstant(HConstant* instr) { |
1426 Representation r = instr->representation(); | 1422 Representation r = instr->representation(); |
1427 if (r.IsInteger32()) { | 1423 if (r.IsInteger32()) { |
1428 int32_t value = instr->Integer32Value(); | 1424 int32_t value = instr->Integer32Value(); |
1429 return DefineAsRegister(new LConstantI(value)); | 1425 return DefineAsRegister(new LConstantI(value)); |
1430 } else if (r.IsDouble()) { | 1426 } else if (r.IsDouble()) { |
1431 double value = instr->DoubleValue(); | 1427 double value = instr->DoubleValue(); |
1432 LOperand* temp = TempRegister(); | 1428 LOperand* temp = TempRegister(); |
1433 return DefineAsRegister(new LConstantD(value, temp)); | 1429 return DefineAsRegister(new LConstantD(value, temp)); |
1434 } else if (r.IsTagged()) { | 1430 } else if (r.IsTagged()) { |
1435 return DefineAsRegister(new LConstantT(instr->handle())); | 1431 return DefineAsRegister(new LConstantT(instr->handle())); |
1436 } else { | 1432 } else { |
1437 UNREACHABLE(); | 1433 UNREACHABLE(); |
1438 return NULL; | 1434 return NULL; |
1439 } | 1435 } |
1440 } | 1436 } |
1441 | 1437 |
1442 | 1438 |
1443 LInstruction* LChunkBuilder::DoLoadGlobal(HLoadGlobal* instr) { | 1439 LInstruction* LChunkBuilder::DoLoadGlobal(HLoadGlobal* instr) { |
1444 LLoadGlobal* result = new LLoadGlobal; | 1440 Abort("Unimplemented: %s", "DoLoadGlobal"); |
1445 return instr->check_hole_value() | 1441 return NULL; |
1446 ? AssignEnvironment(DefineAsRegister(result)) | |
1447 : DefineAsRegister(result); | |
1448 } | 1442 } |
1449 | 1443 |
1450 | 1444 |
1451 LInstruction* LChunkBuilder::DoStoreGlobal(HStoreGlobal* instr) { | 1445 LInstruction* LChunkBuilder::DoStoreGlobal(HStoreGlobal* instr) { |
1452 Abort("Unimplemented: %s", "DoStoreGlobal"); | 1446 Abort("Unimplemented: %s", "DoStoreGlobal"); |
1453 return NULL; | 1447 return NULL; |
1454 } | 1448 } |
1455 | 1449 |
1456 | 1450 |
1457 LInstruction* LChunkBuilder::DoLoadContextSlot(HLoadContextSlot* instr) { | 1451 LInstruction* LChunkBuilder::DoLoadContextSlot(HLoadContextSlot* instr) { |
(...skipping 197 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1655 | 1649 |
1656 | 1650 |
1657 LInstruction* LChunkBuilder::DoLeaveInlined(HLeaveInlined* instr) { | 1651 LInstruction* LChunkBuilder::DoLeaveInlined(HLeaveInlined* instr) { |
1658 Abort("Unimplemented: %s", "DoLeaveInlined"); | 1652 Abort("Unimplemented: %s", "DoLeaveInlined"); |
1659 return NULL; | 1653 return NULL; |
1660 } | 1654 } |
1661 | 1655 |
1662 } } // namespace v8::internal | 1656 } } // namespace v8::internal |
1663 | 1657 |
1664 #endif // V8_TARGET_ARCH_X64 | 1658 #endif // V8_TARGET_ARCH_X64 |
OLD | NEW |