diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-07 19:33:14 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-07 19:33:14 +0000 |
commit | 36d22d82aa202bb199967e9512281e9a53db42c9 (patch) | |
tree | 105e8c98ddea1c1e4784a60a5a6410fa416be2de /js/src/jit-test/tests/jaeger/getelem-sanity-4.js | |
parent | Initial commit. (diff) | |
download | firefox-esr-36d22d82aa202bb199967e9512281e9a53db42c9.tar.xz firefox-esr-36d22d82aa202bb199967e9512281e9a53db42c9.zip |
Adding upstream version 115.7.0esr.upstream/115.7.0esrupstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'js/src/jit-test/tests/jaeger/getelem-sanity-4.js')
-rw-r--r-- | js/src/jit-test/tests/jaeger/getelem-sanity-4.js | 51 |
1 files changed, 51 insertions, 0 deletions
diff --git a/js/src/jit-test/tests/jaeger/getelem-sanity-4.js b/js/src/jit-test/tests/jaeger/getelem-sanity-4.js new file mode 100644 index 0000000000..983713376e --- /dev/null +++ b/js/src/jit-test/tests/jaeger/getelem-sanity-4.js @@ -0,0 +1,51 @@ +var obj = { + attr0: 'val0', + attr1: 'val1', + attr2: 'val2', + attr3: 'val3', + attr4: 'val4', + attr5: 'val5', + attr6: 'val6', + attr7: 'val7', + attr8: 'val8', + attr9: 'val9', + attr10: 'val10', + attr11: 'val11', + attr12: 'val12', + attr13: 'val13', + attr14: 'val14', + attr15: 'val15', + attr16: 'val16', + attr17: 'val17', +} + +var baseName = 'attr'; + +(function() { + for (var i = 0; i < 128; ++i) { + var name = baseName + (i % 18); + var result = obj[name]; + switch (i) { + case 0: assertEq('val0', result); break; + case 1: assertEq('val1', result); break; + case 2: assertEq('val2', result); break; + case 3: assertEq('val3', result); break; + case 4: assertEq('val4', result); break; + case 5: assertEq('val5', result); break; + case 6: assertEq('val6', result); break; + case 7: assertEq('val7', result); break; + case 8: assertEq('val8', result); break; + case 9: assertEq('val9', result); break; + case 10: assertEq('val10', result); break; + case 11: assertEq('val11', result); break; + case 12: assertEq('val12', result); break; + case 13: assertEq('val13', result); break; + case 14: assertEq('val14', result); break; + case 15: assertEq('val15', result); break; + case 16: assertEq('val16', result); break; + case 17: assertEq('val17', result); break; + } + } +})(); + +/* Megamorphic index atom. */ |