-
Notifications
You must be signed in to change notification settings - Fork 35
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
Ubuntu jammy s390x: Test failures #60
Comments
ReproducerI created a minimal reproducer below for the test
x86_64 Fedora 38 (ok)On my local machine.
s390x Ubuntu jammy (not ok?)
DebugDebug 1
On the x86_64, after executing the Lines 1796 to 1805 in 85637fa
On the s390x, after executing the
Debug 2Then I watched when the
x86_64
s390x
Now I want to install a debug symbol of the zlib package to print the lines in the zlib library in Ubuntu jammy. Do you know how to do it? |
All right. Now I was able to install the zlib package's debug symbol package on the s390x server. I executed the page's "Getting -dbgsym.ddeb packages" section. I was not able to install the
But I was able to install the
The zlib debug symbol pacakge's version is same with the zlib package.
|
First, here are the information about the Ubuntu zlib and upsgream zlib.
On the s390x server, I debugged again. I was able to see the code line number now.
Hmm, the debug information is still not enough. I wanted to see the actual codes with lines.
Here is the backtrace.
But I couldn't find https://github.com/madler/zlib/tree/v1.2.11/contrib
I downloaded the Ubuntu jammy zlib package's patch files. https://packages.ubuntu.com/jammy-updates/zlib1g
It seems the
Hmm, I feel it's harder to debug the Ubuntu package than Debian package. Note Debian zlib package link is here. It seems Ubuntu doesn't have the open opened Git repository to track the package's patch files change. And I am family with Fedora Linux packaging things. I found one zlib package s390x issue ticket affecting Ubuntu 22.04 (jammy) in the list of the zlib Ubuntu package bugs. |
It seems that following ticket is related to DFLTCC, reported from s390x machine (= "z15/LinuxONE III" on the ticket). And the PR madler/zlib#410 is reported on the ticket. The PR is adding the |
I plan to run the ruby/zlib unit tests and the minimal reproducer (#60 (comment)), and debug on GDB on Ubuntu focal (the failures didn't happen on Ubuntu focal native s390x server), and newer versions Ubuntu and Fedora rawhide s390x containers on QEMU, and check the difference of the behaviors. |
Hi, madler/zlib#410 author here. Things like
are very likely to break with the DFLTCC hardware accelerator, since it produces a different (but still valid) compressed byte stream than the software implementation. I would suggest to either verify the validity of compressed streams differently (e.g., try to decompress them) or disable DFLTCC by setting the |
Hi @iii-i, thanks for your help providing the info! I ran the reproducing script that I mentioned at #60 (comment) and the ruby/zlib's unit tests again with
And I can see the logic below in the madler/zlib#410 - contrib/s390/dfltcc.c
Comparing the $ diff -u ubuntu_focal/zlib1g/debian/rules ubuntu_jammy/zlib1g/debian/rules
--- ubuntu_focal/zlib1g/debian/rules 2020-08-20 01:52:59.000000000 +0200
+++ ubuntu_jammy/zlib1g/debian/rules 2021-08-12 05:28:03.000000000 +0200
@@ -21,6 +21,9 @@
LDFLAGS = `dpkg-buildflags --get LDFLAGS`
EXTRA_MAKE =
+CONFIGURE_COMMON=--shared --prefix=/usr
+CONFIGURE_HOST=--libdir=\$${prefix}/lib/$(DEB_HOST_MULTIARCH)
+
# binutils doesn't supply the prefixed version normally like GCC does so
# we can't just unconditionally use DEB_HOST_GNU_TYPE-ar
ifeq ($(DEB_HOST_GNU_TYPE),$(DEB_BUILD_GNU_TYPE))
@@ -46,8 +49,9 @@
# s390x fails at compatibility.
ifneq (,$(findstring $(DEB_HOST_ARCH), s390x))
m32=-m31
-CFLAGS += -DDFLTCC
-EXTRA_MAKE += OBJA=dfltcc.o PIC_OBJA=dfltcc.lo
+CFLAGS += -DDFLTCC_LEVEL_MASK=0x7e
+CONFIGURE_COMMON += --dfltcc
+CONFIGURE_HOST += --crc32-vx
else
m32=-m32
endif
@@ -95,7 +99,7 @@
if [ ! -f Makefile.stash ]; then cp Makefile Makefile.stash ; fi
- AR=$(AR) CC="$(DEB_HOST_GNU_TYPE)-gcc" CFLAGS="$(CFLAGS)" LDFLAGS="$(LDFLAGS)" uname=GNU ./configure --shared --prefix=/usr --libdir=\$${prefix}/lib/$(DEB_HOST_MULTIARCH)
+ AR=$(AR) CC="$(DEB_HOST_GNU_TYPE)-gcc" CFLAGS="$(CFLAGS)" LDFLAGS="$(LDFLAGS)" uname=GNU ./configure $(CONFIGURE_COMMON) $(CONFIGURE_HOST)
touch $@
@@ -106,7 +110,7 @@
cp -r $(COPYLIST) debian/64
cd debian/64 && AR=$(AR) CC="$(DEB_HOST_GNU_TYPE)-gcc $(m64)" \
CFLAGS="$(CFLAGS)" LDFLAGS="$(LDFLAGS)" \
- uname=GNU ./configure --shared --prefix=/usr --libdir=\$${prefix}/usr/lib64
+ uname=GNU ./configure $(CONFIGURE_COMMON) --libdir=\$${prefix}/usr/lib64
touch $@
configure32-stamp: configure
@@ -116,7 +120,7 @@
cp -r $(COPYLIST) debian/32
cd debian/32 && AR=$(AR) CC="$(DEB_HOST_GNU_TYPE)-gcc $(m32)" \
CFLAGS="$(CFLAGS)" LDFLAGS="$(LDFLAGS)" \
- uname=GNU ./configure --shared --prefix=/usr --libdir=\$${prefix}/usr/lib32
+ uname=GNU ./configure $(CONFIGURE_COMMON) --libdir=\$${prefix}/usr/lib32
touch $@
configuren32-stamp: configure
@@ -126,7 +130,7 @@
cp -r $(COPYLIST) debian/n32
cd debian/n32 && AR=$(AR) CC="$(DEB_HOST_GNU_TYPE)-gcc $(mn32)" \
CFLAGS="$(CFLAGS)" LDFLAGS="$(LDFLAGS)" \
- uname=GNU ./configure --shared --prefix=/usr --libdir=\$${prefix}/usr/lib32
+ uname=GNU ./configure $(CONFIGURE_COMMON) --libdir=\$${prefix}/usr/lib32
touch $@
configurex32-stamp: configure
@@ -136,7 +140,7 @@
cp -r $(COPYLIST) debian/x32
cd debian/x32 && AR=$(AR) CC="$(DEB_HOST_GNU_TYPE)-gcc $(mx32)" \
CFLAGS="$(CFLAGS)" LDFLAGS="$(LDFLAGS)" \
- uname=GNU ./configure --shared --prefix=/usr --libdir=\$${prefix}/usr/libx32
+ uname=GNU ./configure $(CONFIGURE_COMMON) --libdir=\$${prefix}/usr/libx32
touch $@
build: build-stamp $(EXTRA_BUILD)
Thanks for your suggestion. Right now it seems to me that it's a hard to verify the each test failing with enabled DFLTCC feature, I will send a PR to add a logic to run the ruby/zlib s390x case with |
I sent the PR #63. |
I am seeing the following test failures on RubyCI Ubuntu s390x version Jammy (22.04.3 LTS) on the ruby/zlib latest master branch 85637fa with the latest ruby/ruby master branch. Could you take a look at the failures? I think you can log in to the RubyCI Ubuntu s390x server to debug. Thank you for your help.
Below is the used Zlib deb package version.
ruby/ruby
I also can see the failures in ruby/ruby latest master branch
05a853c2f21f60f9e1c544c2d0709f10de453571
.The text was updated successfully, but these errors were encountered: