Download Jar. Libraryless. Click here for Pure Java version (905L/7K).
1 | !7 |
2 | |
3 | sclass MyClass implements _SetField { |
4 | S a, b, c, d, e, f; |
5 | |
6 | public void _setField(S f, O x) { |
7 | if (f.equals('a)) a = (S) x; |
8 | else if (f.equals('b)) b = (S) x; |
9 | else if (f.equals('c)) c = (S) x; |
10 | else if (f.equals('d)) d = (S) x; |
11 | else if (f.equals('e)) e = (S) x; |
12 | else if (f.equals('f)) f = (S) x; |
13 | } |
14 | } |
15 | |
16 | static volatile new MyClass c; |
17 | |
18 | p { |
19 | int n = tenMillion(); |
20 | repeat 10 { time { |
21 | repeat n { |
22 | c._setField('e, "yo"); |
23 | } |
24 | }} |
25 | printBenchResult(n); |
26 | } |
Began life as a copy of #1011708
download show line numbers debug dex old transpilations
Travelled to 14 computer(s): aoiabmzegqzx, bhatertpkbcr, cbybwowwnfue, cfunsshuasjs, gwrvuhgaqvyk, ishqpsrjomds, lpdgvwnxivlt, mqqgnosmbjvj, ppjhyzlbdabe, pyentgdyhuwx, pzhvpgtvlbxg, tslmcundralx, tvejysmllsmz, vouqrxazstgt
No comments. add comment
Snippet ID: | #1011711 |
Snippet name: | Benchmark _SetField (28 ns) |
Eternal ID of this version: | #1011711/7 |
Text MD5: | 43f6e9a6c6b3325056929c62581f633d |
Transpilation MD5: | 0b0c56d47f622cb825e2f04649a5e4ae |
Author: | stefan |
Category: | javax |
Type: | JavaX source code (desktop) |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2017-11-02 19:08:41 |
Source code size: | 518 bytes / 26 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 452 / 1136 |
Version history: | 6 change(s) |
Referenced in: | [show references] |