Skip to content
This repository has been archived by the owner. It is now read-only.

8269179: Crash in TestMacroLogicVector::testSubWordBoolean: assert(_base >= VectorMask && _base <= VectorZ) failed: Not a Vector #123

Closed
wants to merge 1 commit into from

Conversation

DamonFool
Copy link
Member

@DamonFool DamonFool commented Jun 23, 2021

Hi all,

compiler/vectorization/TestMacroLogicVector.java crashed on AVX512 machines.

Here is the symptom and stack trace:

#
# A fatal error has been detected by the Java Runtime Environment:
#
#  Internal Error (/jdk17/src/hotspot/share/opto/type.hpp:1717), pid=19546, tid=19562
#  assert(_base >= VectorMask && _base <= VectorZ) failed: Not a Vector
#
# JRE version: OpenJDK Runtime Environment (17.0) (slowdebug build 17-internal+0-adhoc.jvm.jdk17)
# Java VM: OpenJDK 64-Bit Server VM (slowdebug 17-internal+0-adhoc.jvm.jdk17, mixed mode, sharing, compressed oops, compressed class ptrs, g1 gc, linux-amd64)
# Problematic frame:
# V  [libjvm.so+0x3b8483]  Type::is_vect() const+0x6b
#


Current CompileTask:
C2:   2275   22 %  b        compiler.vectorization.TestMacroLogicVector::testSubWordBoolean @ 2 (27 bytes)

Stack: [0x00007f0c021fa000,0x00007f0c022fb000],  sp=0x00007f0c022f5e20,  free space=1007k
Native frames: (J=compiled Java code, j=interpreted, Vv=VM code, C=native code)
V  [libjvm.so+0x3b8483]  Type::is_vect() const+0x6b
V  [libjvm.so+0x3da830]  vector_length_in_bytes(Node const*)+0x2b
V  [libjvm.so+0x8b1e97]  State::_sub_Op_MacroLogicV(Node const*)+0x81
V  [libjvm.so+0x8d8014]  State::DFA(int, Node const*)+0x17f6
V  [libjvm.so+0xeceb84]  Matcher::Label_Root(Node const*, State*, Node*, Node*&)+0x4c0
V  [libjvm.so+0xece218]  Matcher::match_tree(Node const*)+0x206
V  [libjvm.so+0xecc40b]  Matcher::xform(Node*, int)+0x1f3
V  [libjvm.so+0xec75f9]  Matcher::match()+0xdc7
V  [libjvm.so+0x7d9e01]  Compile::Code_Gen()+0x95
V  [libjvm.so+0x7d10f5]  Compile::Compile(ciEnv*, ciMethod*, int, bool, bool, bool, bool, bool, DirectiveSet*)+0x160f
V  [libjvm.so+0x6c17c8]  C2Compiler::compile_method(ciEnv*, ciMethod*, int, bool, DirectiveSet*)+0x144
V  [libjvm.so+0x7ee2ed]  CompileBroker::invoke_compiler_on_method(CompileTask*)+0x97d
V  [libjvm.so+0x7ece21]  CompileBroker::compiler_thread_loop()+0x3dd
V  [libjvm.so+0x80d1ab]  CompilerThread::thread_entry(JavaThread*, JavaThread*)+0x69
V  [libjvm.so+0x12857f1]  JavaThread::thread_main_inner()+0x17b
V  [libjvm.so+0x1285669]  JavaThread::run()+0x1d7
V  [libjvm.so+0x1282e40]  Thread::call_run()+0x180
V  [libjvm.so+0xfc255b]  thread_native_entry(Thread*)+0x18f

The reason is that for vpternlog_mem, n->in(1) points to BinaryNode.
This is incorrect since BinaryNode->bottom_type() returns Type::BOTTOM.
So it should be something like n->in(1)->in(1).

Thanks.
Best regards,
Jie


Progress

  • Change must not contain extraneous whitespace
  • Commit message must refer to an issue
  • Change must be properly reviewed

Issue

  • JDK-8269179: Crash in TestMacroLogicVector::testSubWordBoolean: assert(_base >= VectorMask && _base <= VectorZ) failed: Not a Vector

Reviewers

Reviewing

Using git

Checkout this PR locally:
$ git fetch https://git.openjdk.java.net/jdk17 pull/123/head:pull/123
$ git checkout pull/123

Update a local copy of the PR:
$ git checkout pull/123
$ git pull https://git.openjdk.java.net/jdk17 pull/123/head

Using Skara CLI tools

Checkout this PR locally:
$ git pr checkout 123

View PR using the GUI difftool:
$ git pr show -t 123

Using diff file

Download this PR as a diff file:
https://git.openjdk.java.net/jdk17/pull/123.diff

…ase >= VectorMask && _base <= VectorZ) failed: Not a Vector
@bridgekeeper
Copy link

@bridgekeeper bridgekeeper bot commented Jun 23, 2021

👋 Welcome back jiefu! A progress list of the required criteria for merging this PR into master will be added to the body of your pull request. There are additional pull request commands available for use with this pull request.

@openjdk openjdk bot added the rfr label Jun 23, 2021
@openjdk
Copy link

@openjdk openjdk bot commented Jun 23, 2021

@DamonFool The following label will be automatically applied to this pull request:

  • hotspot-compiler

When this pull request is ready to be reviewed, an "RFR" email will be sent to the corresponding mailing list. If you would like to change these labels, use the /label pull request command.

@openjdk openjdk bot added the hotspot-compiler label Jun 23, 2021
@mlbridge
Copy link

@mlbridge mlbridge bot commented Jun 23, 2021

Webrevs

@jatin-bhateja
Copy link
Member

@jatin-bhateja jatin-bhateja commented Jun 23, 2021

Check introduced by 8267652, fix looks good to me.

Copy link
Contributor

@vnkozlov vnkozlov left a comment

Good.

@openjdk
Copy link

@openjdk openjdk bot commented Jun 23, 2021

@DamonFool This change now passes all automated pre-integration checks.

ℹ️ This project also has non-automated pre-integration requirements. Please see the file CONTRIBUTING.md for details.

After integration, the commit message for the final commit will be:

8269179: Crash in TestMacroLogicVector::testSubWordBoolean: assert(_base >= VectorMask && _base <= VectorZ) failed: Not a Vector

Reviewed-by: kvn, neliasso

You can use pull request commands such as /summary, /contributor and /issue to adjust it as needed.

At the time when this comment was updated there had been no new commits pushed to the master branch. If another commit should be pushed before you perform the /integrate command, your PR will be automatically rebased. If you prefer to avoid any potential automatic rebasing, please check the documentation for the /integrate command for further details.

➡️ To integrate this PR with the above commit message to the master branch, type /integrate in a new comment.

@openjdk openjdk bot added the ready label Jun 23, 2021
Copy link

@neliasso neliasso left a comment

Looks good. Thanks for fixing!

@DamonFool
Copy link
Member Author

@DamonFool DamonFool commented Jun 24, 2021

Thanks @jatin-bhateja , @vnkozlov and @neliasso .
/integrate

@openjdk
Copy link

@openjdk openjdk bot commented Jun 24, 2021

Going to push as commit a30141d.
Since your change was applied there have been 7 commits pushed to the master branch:

  • b474314: 8266854: LibraryCallKit::inline_preconditions_checkIndex modifies control flow even if the intrinsic bailed out
  • 7e96318: 8254571: Erroneous generic type inference in a lambda expression with a checked exception
  • 1b2147a: 8269125: Klass enqueue element size calculation wrong when traceid value cross compress limit
  • bf70620: 8268961: Parenthesized pattern with guards does not work
  • 8128ca1: 8269066: assert(ZAddress::is_marked(addr)) failed: Should be marked
  • 1323be5: 8269064: Dropped messages of AsyncLogWriter cause memleak
  • ce917b2: 8269148: Update minor GCC version in GitHub Actions pipeline

Your commit was automatically rebased without conflicts.

@openjdk openjdk bot closed this Jun 24, 2021
@openjdk openjdk bot added integrated and removed ready rfr labels Jun 24, 2021
@openjdk
Copy link

@openjdk openjdk bot commented Jun 24, 2021

@DamonFool Pushed as commit a30141d.

💡 You may see a message that your pull request was closed with unmerged commits. This can be safely ignored.

@DamonFool DamonFool deleted the JDK-8269179 branch Jun 24, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
hotspot-compiler integrated
4 participants