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

libpcre2-10.43 broken on gcc2 #10138

Open
Begasus opened this issue Feb 23, 2024 · 20 comments
Open

libpcre2-10.43 broken on gcc2 #10138

Begasus opened this issue Feb 23, 2024 · 20 comments

Comments

@Begasus
Copy link
Contributor

Begasus commented Feb 23, 2024

Latest (at this moment) can't be build with gcc2, parse errors, I got a few fixed by lot's of others there (skill are not up to that).

@threedeyes
Copy link
Member

After the update libpcre2 (9130150), Qt applications stop working under 32 bit Haiku. The error is invalid opcode exception. If you roll back libpcre2 version, the problem disappears.

@Begasus
Copy link
Contributor Author

Begasus commented Feb 29, 2024

@threedeyes is this with the new version?
I've got latest x86 (10.43 and an older one 8.45) installed and 10.39 for gcc2, Qt-Assistant for instance still launches (on R1B4 still though).

@Begasus
Copy link
Contributor Author

Begasus commented Feb 29, 2024

Should 10.43 be reverted to 10.42?
EDIT: or rolled back to 10.39 also for x86?

@augiedoggie
Copy link
Contributor

I noticed this problem with KeePassXC last night on a fully updated R1/B4 installation.

@Begasus
Copy link
Contributor Author

Begasus commented Feb 29, 2024

The 32bit install here is a fully synced R1B4 also here, launches fine here after installing on both 32bit and 64bit?

@Begasus
Copy link
Contributor Author

Begasus commented Feb 29, 2024

Screenshot taken a minute ago:

KeePassXC

@Begasus
Copy link
Contributor Author

Begasus commented Feb 29, 2024

Updated screenshot with pcre2 packages installed:

KeePassXC

@threedeyes
Copy link
Member

threedeyes commented Mar 1, 2024

The 32bit install here is a fully synced R1B4 also here, launches fine here after installing on both 32bit and 64bit?

The problem is reproduced on a fully updated R1B4 32bit. When running any applications using libpcre2 (including Qt applications) I get invalid opcode exception. Also apparently this package build failed for the same reason - https://build.haiku-os.org/buildmaster/master/x86_gcc2/logviewer.html?buildruns/5789/builds/82857.log

The error code says, the problem may be related to the processor type and appear on different same. Perhaps some optimizations were enabled when building the new version of libpcre2?

PS: I have AMD Rizen 7.

@augiedoggie
Copy link
Contributor

I attempted to rebuild 10.43 in my VM and run the test suite with hp --test libpcre2_x86 and it continuously crashed with invalid opcodes. I'm on a Ryzen 5.

@Begasus
Copy link
Contributor Author

Begasus commented Mar 1, 2024

Intel I5 here, will do testbuilds on 32bit with 10.39 and 10.43 to build kdoctools, if it fails on the newer one I'll disable the newer one untill this is fixed (or either of you can if you beat me to it).

@Begasus
Copy link
Contributor Author

Begasus commented Mar 1, 2024

Changes done from 10.42 to 10.43 shown here: https://fossies.org/diffs/pcre2/10.42_vs_10.43/
Maybe something broke it for us, PR to bring back 10.42 is done, please check.

@threedeyes
Copy link
Member

Changes done from 10.42 to 10.43 shown here: https://fossies.org/diffs/pcre2/10.42_vs_10.43/
Maybe something broke it for us, PR to bring back 10.42 is done, please check.

I see added autodetecting cpu code in 10.43

@Begasus
Copy link
Contributor Author

Begasus commented Mar 1, 2024

I see added autodetecting cpu code in 10.43

Right, mentioned this earlier in IRC, probably explains different errors you see there that I don't see here.

@threedeyes
Copy link
Member

I see added autodetecting cpu code in 10.43

Right, mentioned this earlier in IRC, probably explains different errors you see there that I don't see here.

I found the problem - AVX2 instructions. The 32bit version of Haiku does not support them. If you disable them, everything works fine.

https://github.com/PCRE2Project/pcre2/blob/master/src/sljit/sljitNativeX86_common.c#L511

@Begasus
Copy link
Contributor Author

Begasus commented Mar 1, 2024

Eeps, just merged to revert to 10.42, will do some testruns to disable that (or you could take care of that), in the meantime checked a build for kdoctools 5.115.0 on 32bit, didn't error out here.

@Begasus
Copy link
Contributor Author

Begasus commented Mar 1, 2024

@threedeyes maybe you could push kdoctools again for the buildmasters, libpcre2 10.42 is ready there, if that works well we can wait with bumping/fixing libpcre2 10.43 untill you are done for the KDE updates.

@threedeyes
Copy link
Member

@threedeyes maybe you could push kdoctools again for the buildmasters, libpcre2 10.42 is ready there, if that works well we can wait with bumping/fixing libpcre2 10.43 untill you are done for the KDE updates.

I tested 10.43 with AVX2 disabled - kconfig and kdoctools compiled successfully.

@Begasus
Copy link
Contributor Author

Begasus commented Mar 1, 2024

OK, then you could push the change to get 10.43 back in the depot :)

@threedeyes
Copy link
Member

Then it probably makes sense to set the revision number to 2 to update those who got a non-functional version after the last update.

@Begasus
Copy link
Contributor Author

Begasus commented Mar 1, 2024

Right, and to be sure the local packages get the correct version installed. +1

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

No branches or pull requests

3 participants