Libraryless. Click here for Pure Java version (881L/6K/22K).
!752 sclass QuickThrowable extends Throwable { public Throwable fillInStackTrace() { ret this; } } static int n = 1000000; static O o; // Difference might be even bigger than factor 100 with longer stack traces. p { twice { time { for i to n: o = new Throwable; } time { for i to n: o = new QuickThrowable; } } }
download show line numbers debug dex old transpilations
Travelled to 16 computer(s): aoiabmzegqzx, bhatertpkbcr, cbybwowwnfue, cfunsshuasjs, ddnzoavkxhuk, gwrvuhgaqvyk, ishqpsrjomds, jtubtzbbkimh, lpdgvwnxivlt, mqqgnosmbjvj, nbgitpuheiab, pyentgdyhuwx, pzhvpgtvlbxg, tslmcundralx, tvejysmllsmz, vouqrxazstgt
No comments. add comment
| Snippet ID: | #1005659 | 
| Snippet name: | Benchmark Quick Exceptions (QuickException/QuickThrowable) vs normal exceptions - 40 ns vs 4 µs (factor 100) | 
| Eternal ID of this version: | #1005659/4 | 
| Text MD5: | fb04c20c0e3f215e6d5e7854915fb3d8 | 
| Transpilation MD5: | a297c21a17d72f7e2026f3c7801efa96 | 
| Author: | stefan | 
| Category: | javax | 
| Type: | JavaX source code | 
| Public (visible to everyone): | Yes | 
| Archived (hidden from active list): | No | 
| Created/modified: | 2017-12-07 14:41:27 | 
| Source code size: | 376 bytes / 22 lines | 
| Pitched / IR pitched: | No / No | 
| Views / Downloads: | 834 / 901 | 
| Version history: | 3 change(s) | 
| Referenced in: | [show references] |