Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[3.2] Added Linux sanitizer with xvfb to github workspace #40994

Merged
merged 1 commit into from
Oct 1, 2020

Conversation

qarmin
Copy link
Contributor

@qarmin qarmin commented Aug 3, 2020

This PR allow CI to tests editor with virtual desktop with specific project

It:

  • Download project - https://github.com/qarmin/RegressionTestProject/tree/3.2 - which add to scene all nodes.
    Godot should have "official" test project which could tests importing files(png, fbx, glb), executing basic functions etc.

  • Run editor - to import files which allows to run project later

  • Run project - with parameter which shows how long project will be executed(in second) - it runs only with renderer - GLES 3 - with master now this isn't possible due using Vulkan
    Every single error is saved to log file, and after each command file is checked if contains specific text which is the result of an error.

There is a bug with running this specific project with GLES 2 inside xvfb-run, because at the end it shows Segmentation fault(core dumped), so for now this step is missing.
It is blocked by #37665 (seems that not always crash engine) and other issues with leaks

@qarmin
Copy link
Contributor Author

qarmin commented Aug 3, 2020

I have a problem with implementing properly working solution to get leaks without failing CI when finding thirdparty leak.

When leak or usage of invalid memory happens, then this command return 1 which cause build failue
There is a problem with thirdparty leaks e.g.

Indirect leak of 56 byte(s) in 1 object(s) allocated from:
    #0 0x7f0d4ef11dc6 in calloc (/lib/x86_64-linux-gnu/libasan.so.5+0x10ddc6)
    #1 0x7f9db041873d  (<unknown module>)
    #2 0x7f9db040a665  (<unknown module>)

which is impossible to fix in Godot code and suppress.

The solution for me is to disable exit code by adding e.g. || exit 0, save result to file and later check if inside file is text:

  • "AddressSanitizer" - This is always error
  • "LeakSanitizer" - Shows leaks, but needs to be suppress, I think that finding text #4 should be enough to check if there are "real" leaks or not(thirdparty leaks usually are smaller like in example from above)

@qarmin
Copy link
Contributor Author

qarmin commented Aug 13, 2020

I also removed option to use specific binaries optimization e.g. for size, when using full debug symbols, because they compile too long.

Also I must add workaround for importing Godot project, because godot -e -q doesn't always properly import all scenes/resources

@akien-mga akien-mga merged commit 0c3e0ab into godotengine:3.2 Oct 1, 2020
@akien-mga
Copy link
Member

Thanks!

akien-mga added a commit to akien-mga/godot that referenced this pull request Oct 1, 2020
Added in godotengine#40994 but without recent rebase, so they don't pass currently.
@akien-mga
Copy link
Member

akien-mga commented Oct 28, 2020

@qarmin
Copy link
Contributor Author

qarmin commented Oct 28, 2020

Accidentally I pushed changes to 3.2 branch instead my own PR, and after that I probably reverted too much.

EDIT: Still something not works, better is for now disable exported build, until I found a cause of this behaviour

I working now on adding CI to this project to avoid crashes/failed CI when upgrading project - https://github.com/qarmin/RegressionTestProject/pull/3

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants