Skip to content

More stage1 test coverage#15879

Merged
andrewrk merged 13 commits intomasterfrom
unknown repository
Jul 3, 2023
Merged

More stage1 test coverage#15879
andrewrk merged 13 commits intomasterfrom
unknown repository

Conversation

@ghost
Copy link

@ghost ghost commented May 28, 2023

No description provided.

Copy link
Member

@andrewrk andrewrk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great work. You mind doing one last rebase and then I'll mark this as auto-merge?

@ghost
Copy link
Author

ghost commented Jun 15, 2023

I'm pretty sure I didn't change anything that would cause this new failure that previously didn't happen:

zig build-exe maximum_sized_integer_literal Debug x86_64-windows: error: thread 229607 panic: Segmentation fault at address 0xffff37fc3934
/home/ci/actions-runner8/_work/zig/zig/src/link/Coff.zig:1504:29: 0x44d1bb0 in updateDeclExports (zig)
        sym.value = decl_sym.value;
                            ^
/home/ci/actions-runner8/_work/zig/zig/src/link/Coff.zig:1194:34: 0x44c39b3 in updateDecl (zig)
    return self.updateDeclExports(mod, decl_index, mod.getDeclExports(decl_index));
                                 ^
/home/ci/actions-runner8/_work/zig/zig/src/link.zig:551:77: 0x428771b in updateDecl (zig)
            .coff  => return @fieldParentPtr(Coff,  "base", base).updateDecl(module, decl_index),
                                                                            ^

Pretty sure all I did was resolve the conflict and rebase on master/the InternPool changes.
Might be a regression. I added a if (builtin.os.tag == .windows) return; to test/cases/maximum_sized_integer_literal.zig for now.

Copy link
Member

@andrewrk andrewrk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmm, I did not take as close a look at the new test cases last time as I should have.

Please use panics instead of illegal behavior (i.e. assert) so that the tests are meaningful in safety-off optimization modes as well.

Also please use behavior tests where possible instead of run test cases.

@ghost
Copy link
Author

ghost commented Jun 15, 2023

Oh, that is very true. I must've just taken that idea from other tests without thinking about it enough.

It's also very good to know that behavior tests are in fact preferable.

@ghost
Copy link
Author

ghost commented Jun 16, 2023

zig test Debug mips-linux-none: error: Assertion failed: ShiftAmt <= BitWidth && "Invalid shift amount" (/home/andy/dev/zig-bootstrap/llvm/include/llvm/ADT/APInt.h: lshrInPlace: 847)

zig test Debug mips-linux-none: error: the following command terminated unexpectedly:
/home/ci/actions-runner5/_work/zig/zig/build-debug/stage3-debug/bin/zig test /home/ci/actions-runner5/_work/zig/zig/test/behavior.zig --cache-dir /home/ci/actions-runner5/_work/zig/zig/build-debug/zig-local-cache --global-cache-dir /home/ci/actions-runner5/_work/zig/zig/build-debug/zig-global-cache --name test -target mips-linux-none -mcpu mips32 -I /home/ci/actions-runner5/_work/zig/zig/test -L /home/ci/deps/zig+llvm+lld+clang-x86_64-linux-musl-0.11.0-dev.1869+df4cfc2ec/lib -I /home/ci/deps/zig+llvm+lld+clang-x86_64-linux-musl-0.11.0-dev.1869+df4cfc2ec/include --zig-lib-dir /home/ci/actions-runner5/_work/zig/zig/lib --listen=- 
zig test Debug mips-linux-musl: error: Assertion failed: ShiftAmt <= BitWidth && "Invalid shift amount" (/home/andy/dev/zig-bootstrap/llvm/include/llvm/ADT/APInt.h: lshrInPlace: 847)

Interesting. This has also not previously happened before the rebase.

Anyway, AFAIU the zig downloads are broken right now so I'm going to wait till I can get the latest master from the download page.

@ghost
Copy link
Author

ghost commented Jun 19, 2023

I'm going to try limiting tests that I think might have to do with the failure to linux-x86_64 for now.

@jacobly0
Copy link
Member

I'm going to try limiting tests that I think might have to do with the failure to linux-x86_64 for now.

Vectors are a likely culprit: #13782

@ghost
Copy link
Author

ghost commented Jun 20, 2023

Thanks! That helps a lot.

@andrewrk andrewrk merged commit 17890f6 into ziglang:master Jul 3, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants