Commit d5762717 authored by danno@chromium.org's avatar danno@chromium.org

Fix bug in test-code-stubs-x64 which meant not all registers were being checked.

Also change test-code-stubs-ia32 to use the same style as x64.

BUG=
R=danno@chromium.org

Review URL: https://codereview.chromium.org/22865006

Patch from Ross McIlroy <mcilroy@chromium.org>.

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@16203 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
parent aaeca64d
......@@ -136,46 +136,15 @@ TEST(ConvertDToI) {
RunAllTruncationTests(&ConvertDToICVersion);
#endif
RunAllTruncationTests(MakeConvertDToIFuncTrampoline(isolate, esp, eax));
RunAllTruncationTests(MakeConvertDToIFuncTrampoline(isolate, esp, ebx));
RunAllTruncationTests(MakeConvertDToIFuncTrampoline(isolate, esp, ecx));
RunAllTruncationTests(MakeConvertDToIFuncTrampoline(isolate, esp, edx));
RunAllTruncationTests(MakeConvertDToIFuncTrampoline(isolate, esp, edi));
RunAllTruncationTests(MakeConvertDToIFuncTrampoline(isolate, esp, esi));
RunAllTruncationTests(MakeConvertDToIFuncTrampoline(isolate, eax, eax));
RunAllTruncationTests(MakeConvertDToIFuncTrampoline(isolate, eax, ebx));
RunAllTruncationTests(MakeConvertDToIFuncTrampoline(isolate, eax, ecx));
RunAllTruncationTests(MakeConvertDToIFuncTrampoline(isolate, eax, edx));
RunAllTruncationTests(MakeConvertDToIFuncTrampoline(isolate, eax, edi));
RunAllTruncationTests(MakeConvertDToIFuncTrampoline(isolate, eax, esi));
RunAllTruncationTests(MakeConvertDToIFuncTrampoline(isolate, ebx, eax));
RunAllTruncationTests(MakeConvertDToIFuncTrampoline(isolate, ebx, ebx));
RunAllTruncationTests(MakeConvertDToIFuncTrampoline(isolate, ebx, ecx));
RunAllTruncationTests(MakeConvertDToIFuncTrampoline(isolate, ebx, edx));
RunAllTruncationTests(MakeConvertDToIFuncTrampoline(isolate, ebx, edi));
RunAllTruncationTests(MakeConvertDToIFuncTrampoline(isolate, ebx, esi));
RunAllTruncationTests(MakeConvertDToIFuncTrampoline(isolate, ecx, eax));
RunAllTruncationTests(MakeConvertDToIFuncTrampoline(isolate, ecx, ebx));
RunAllTruncationTests(MakeConvertDToIFuncTrampoline(isolate, ecx, ecx));
RunAllTruncationTests(MakeConvertDToIFuncTrampoline(isolate, ecx, edx));
RunAllTruncationTests(MakeConvertDToIFuncTrampoline(isolate, ecx, edi));
RunAllTruncationTests(MakeConvertDToIFuncTrampoline(isolate, ecx, esi));
RunAllTruncationTests(MakeConvertDToIFuncTrampoline(isolate, edx, eax));
RunAllTruncationTests(MakeConvertDToIFuncTrampoline(isolate, edx, ebx));
RunAllTruncationTests(MakeConvertDToIFuncTrampoline(isolate, edx, ecx));
RunAllTruncationTests(MakeConvertDToIFuncTrampoline(isolate, edx, edx));
RunAllTruncationTests(MakeConvertDToIFuncTrampoline(isolate, edx, edi));
RunAllTruncationTests(MakeConvertDToIFuncTrampoline(isolate, edx, esi));
RunAllTruncationTests(MakeConvertDToIFuncTrampoline(isolate, esi, eax));
RunAllTruncationTests(MakeConvertDToIFuncTrampoline(isolate, esi, ebx));
RunAllTruncationTests(MakeConvertDToIFuncTrampoline(isolate, esi, ecx));
RunAllTruncationTests(MakeConvertDToIFuncTrampoline(isolate, esi, edx));
RunAllTruncationTests(MakeConvertDToIFuncTrampoline(isolate, esi, edi));
RunAllTruncationTests(MakeConvertDToIFuncTrampoline(isolate, esi, esi));
RunAllTruncationTests(MakeConvertDToIFuncTrampoline(isolate, edi, eax));
RunAllTruncationTests(MakeConvertDToIFuncTrampoline(isolate, edi, ebx));
RunAllTruncationTests(MakeConvertDToIFuncTrampoline(isolate, edi, ecx));
RunAllTruncationTests(MakeConvertDToIFuncTrampoline(isolate, edi, edx));
RunAllTruncationTests(MakeConvertDToIFuncTrampoline(isolate, edi, edi));
RunAllTruncationTests(MakeConvertDToIFuncTrampoline(isolate, edi, esi));
Register source_registers[] = {esp, eax, ebx, ecx, edx, edi, esi};
Register dest_registers[] = {eax, ebx, ecx, edx, edi, esi};
for (size_t s = 0; s < sizeof(source_registers) / sizeof(Register); s++) {
for (size_t d = 0; d < sizeof(dest_registers) / sizeof(Register); d++) {
RunAllTruncationTests(
MakeConvertDToIFuncTrampoline(isolate,
source_registers[s],
dest_registers[d]));
}
}
}
......@@ -138,8 +138,8 @@ TEST(ConvertDToI) {
Register source_registers[] = {rsp, rax, rbx, rcx, rdx, rsi, rdi, r8, r9};
Register dest_registers[] = {rax, rbx, rcx, rdx, rsi, rdi, r8, r9};
for (size_t s = 0; s < sizeof(*source_registers); s++) {
for (size_t d = 0; d < sizeof(*dest_registers); d++) {
for (size_t s = 0; s < sizeof(source_registers) / sizeof(Register); s++) {
for (size_t d = 0; d < sizeof(dest_registers) / sizeof(Register); d++) {
RunAllTruncationTests(
MakeConvertDToIFuncTrampoline(isolate,
source_registers[s],
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment