RFR: 8335334: Stress mode to randomly execute unstable if traps [v3]

Vladimir Kozlov kvn at openjdk.org
Wed Sep 18 18:02:07 UTC 2024


On Wed, 18 Sep 2024 10:54:40 GMT, Tobias Hartmann <thartmann at openjdk.org> wrote:

>> src/hotspot/share/opto/parse2.cpp line 1385:
>> 
>>> 1383:   bool do_stress_trap = StressUnstableIfTraps && ((C->random() % 2) == 0);
>>> 1384:   if (do_stress_trap) {
>>> 1385:     Node* counter_addr = makecon(TypeRawPtr::make((address)&_trap_stress_counter));
>> 
>> Would it be easier if you use new Ideal macro node for this and expand it in macro expansion phase?
>
> I think the problem with a macro node is that it might prevent optimizations that look through the memory graph, especially since the macro node would need to read and update (raw) memory. Also, such a simple load, increment and store does not pollute the graph too much to justify a macro node, I my opinion.

okay

-------------

PR Review Comment: https://git.openjdk.org/jdk/pull/21037#discussion_r1765485166


More information about the hotspot-dev mailing list