beehive-lab / TornadoVM

TornadoVM: A practical and efficient heterogeneous programming framework for managed languages
https://www.tornadovm.org
Apache License 2.0
1.16k stars 109 forks source link

[fix] event list size increased to accomodate profiling of large appl… #380

Closed jjfumero closed 3 months ago

jjfumero commented 3 months ago

Description

This PR increases the internal event list to process large applications. The event list size can be tuned using the following flag:

-Dtornado.max.events=8192

Problem description

The issue was that, when processing large applications, the default size list was too small to accommodate all pending events. This fixes one of the GAIA kernels.

Backend/s tested

Mark the backends affected by this PR.

OS tested

Mark the OS where this PR is tested.

Did you check on FPGAs?

If it is applicable, check your changes on FPGAs.

How to test the new patch?

$ make 
$ tornado-test -V --fast uk.ac.manchester.tornado.unittests.multithreaded.TestMultiThreadedExecutionPlans#test03

The number 4 (test04 is expected to fail and is related to another issue with the cleanup. We will push a new PR with that fix.

stratika commented 3 months ago

Is this the expected outcome?

tornado-test -V --fast uk.ac.manchester.tornado.unittests.multithreaded.TestMultiThreadedExecutionPlans#test03
tornado --jvm "-Xmx6g -Dtornado.recover.bailout=False -Dtornado.unittests.verbose=True "  -m  tornado.unittests/uk.ac.manchester.tornado.unittests.tools.TornadoTestRunner  --params "uk.ac.manchester.tornado.unittests.multithreaded.TestMultiThreadedExecutionPlans#test03"
WARNING: Using incubator modules: jdk.incubator.vector
Context leak detected, msgtracer returned -1
Context leak detected, msgtracer returned -1
Context leak detected, msgtracer returned -1
Test: class uk.ac.manchester.tornado.unittests.multithreaded.TestMultiThreadedExecutionPlans#test03
    Running test: test03                     ................  [PASS] 
Test ran: 1, Failed: 0, Unsupported: 0
jjfumero commented 3 months ago

I don't get this error. Where is this message coming from? the driver?

stratika commented 3 months ago

I don't get this error. Where is this message coming from? the driver?

macOS M1 chip.

version=1.0.4-dev
branch=fix/events/multithread
commit=49b4566

Backends installed: 
     - opencl
mikepapadim commented 3 months ago

It works for me on Pop!_OS 22.04 LTS

jjfumero commented 3 months ago

Ok, if no errors then we can merge.