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

AND intrinsic [extension] with BOZ argument [additional extension] #794

Closed
oroppas opened this issue May 22, 2021 · 4 comments
Closed

AND intrinsic [extension] with BOZ argument [additional extension] #794

oroppas opened this issue May 22, 2021 · 4 comments
Labels
enhancement New feature or request

Comments

@oroppas
Copy link

oroppas commented May 22, 2021

I managed to crash bbc by the following code:

      program main
      integer i

      i = and(Z'F',Z'3')

      print *, Z'F'
      print *, Z'3'
      print *, i

      end program main

with the output

fatal internal error: CHECK(kind_ > 0) failed at /home/ryuta/packages/llvm/flang/f18-llvm-project/flang/include/flang/Evaluate/type.h(137)

followed by huge stack dump

0.      Program arguments: /home/ryuta/packages/llvm/flang/build/bin/bbc and.f
 #0 0x00007ff16aa54633 llvm::sys::PrintStackTrace(llvm::raw_ostream&, int) (/home/ryuta/packages/llvm/flang/build/lib/libLLVMSupport.so.13git+0x202633)
 #1 0x00007ff16aa51eae llvm::sys::RunSignalHandlers() (/home/ryuta/packages/llvm/flang/build/lib/libLLVMSupport.so.13git+0x1ffeae)
 #2 0x00007ff16aa54ecf SignalHandler(int) Signals.cpp:0:0
 #3 0x00007ff16de6a630 __restore_rt sigaction.c:0:0
 #4 0x00007ff16a085387 raise (/lib64/libc.so.6+0x36387)
 #5 0x00007ff16a086a78 abort (/lib64/libc.so.6+0x37a78)
 #6 0x00007ff16b038e86 (/home/ryuta/packages/llvm/flang/build/lib/libFortranCommon.so.13git+0x2e86)
 #7 0x00007ff16dbb2c3b Fortran::lower::CallInterfaceImpl<Fortran::lower::CallerInterface>::translateDynamicType(Fortran::evaluate::DynamicType const&) CallInterface.cpp:0:0
 #8 0x00007ff16dbb3468 Fortran::lower::CallInterfaceImpl<Fortran::lower::CallerInterface>::handleImplicitDummy(Fortran::evaluate::characteristics::DummyDataObject const&, Fortran::evaluate::ActualArgument const* const&) CallInterface.cpp:0:0
 #9 0x00007ff16dbb3215 decltype(auto) std::__1::__variant_detail::__visitation::__base::__dispatcher<0ul>::__dispatch<std::__1::__variant_detail::__visitation::__variant::__value_visitor<Fortran::common::visitors<Fortran::lower::CallInterfaceImpl<Fortran::lower::CallerInterface>::buildImplicitInterface(Fortran::evaluate::characteristics::Procedure const&)::'lambda'(auto const&), Fortran::lower::CallInterfaceImpl<Fortran::lower::CallerInterface>::buildImplicitInterface(Fortran::evaluate::characteristics::Procedure const&)::'lambda'(Fortran::evaluate::characteristics::AlternateReturn const&)> >&&, std::__1::__variant_detail::__base<(std::__1::__variant_detail::_Trait)1, Fortran::evaluate::characteristics::DummyDataObject, Fortran::evaluate::characteristics::DummyProcedure, Fortran::evaluate::characteristics::AlternateReturn> const&>(auto, std::__1::__variant_detail::__visitation::__variant::__value_visitor<Fortran::common::visitors<Fortran::lower::CallInterfaceImpl<Fortran::lower::CallerInterface>::buildImplicitInterface(Fortran::evaluate::characteristics::Procedure const&)::'lambda'(auto const&), Fortran::lower::CallInterfaceImpl<Fortran::lower::CallerInterface>::buildImplicitInterface(Fortran::evaluate::characteristics::Procedure const&)::'lambda'(Fortran::evaluate::characteristics::AlternateReturn const&)> >&&...) CallInterface.cpp:0:0
#10 0x00007ff16dbad052 Fortran::lower::CallInterfaceImpl<Fortran::lower::CallerInterface>::buildImplicitInterface(Fortran::evaluate::characteristics::Procedure const&) CallInterface.cpp:0:0
#11 0x00007ff16dbad749 Fortran::lower::CallInterface<Fortran::lower::CallerInterface>::declare() (/home/ryuta/packages/llvm/flang/build/lib/libFortranLower.so.13git+0x1fe749)
#12 0x00007ff16dbc5b8e Fortran::lower::CallerInterface::CallerInterface(Fortran::evaluate::ProcedureRef const&, Fortran::lower::AbstractConverter&) ConvertExpr.cpp:0:0
#13 0x00007ff16dbc2145 (anonymous namespace)::ScalarExprLowering::genProcedureRef(Fortran::evaluate::ProcedureRef const&, llvm::Optional<mlir::Type>) ConvertExpr.cpp:0:0
#14 0x00007ff16dbfeea1 decltype(auto) std::__1::__variant_detail::__visitation::__base::__dispatcher<15ul>::__dispatch<std::__1::__variant_detail::__visitation::__variant::__value_visitor<fir::ExtendedValue (anonymous namespace)::ScalarExprLowering::genval<Fortran::evaluate::Type<(Fortran::common::TypeCategory)1, 4> >(Fortran::evaluate::Expr<Fortran::evaluate::Type<(Fortran::common::TypeCategory)1, 4> > const&)::'lambda'(Fortran::evaluate::Type<(Fortran::common::TypeCategory)1, 4> const&)>&&, std::__1::__variant_detail::__base<(std::__1::__variant_detail::_Trait)1, Fortran::evaluate::ComplexComponent<4>, Fortran::evaluate::Parentheses<Fortran::evaluate::Type<(Fortran::common::TypeCategory)1, 4> >, Fortran::evaluate::Negate<Fortran::evaluate::Type<(Fortran::common::TypeCategory)1, 4> >, Fortran::evaluate::Add<Fortran::evaluate::Type<(Fortran::common::TypeCategory)1, 4> >, Fortran::evaluate::Subtract<Fortran::evaluate::Type<(Fortran::common::TypeCategory)1, 4> >, Fortran::evaluate::Multiply<Fortran::evaluate::Type<(Fortran::common::TypeCategory)1, 4> >, Fortran::evaluate::Divide<Fortran::evaluate::Type<(Fortran::common::TypeCategory)1, 4> >, Fortran::evaluate::Power<Fortran::evaluate::Type<(Fortran::common::TypeCategory)1, 4> >, Fortran::evaluate::RealToIntPower<Fortran::evaluate::Type<(Fortran::common::TypeCategory)1, 4> >, Fortran::evaluate::Extremum<Fortran::evaluate::Type<(Fortran::common::TypeCategory)1, 4> >, Fortran::evaluate::Convert<Fortran::evaluate::Type<(Fortran::common::TypeCategory)1, 4>, (Fortran::common::TypeCategory)0>, Fortran::evaluate::Convert<Fortran::evaluate::Type<(Fortran::common::TypeCategory)1, 4>, (Fortran::common::TypeCategory)1>, Fortran::evaluate::Constant<Fortran::evaluate::Type<(Fortran::common::TypeCategory)1, 4> >, Fortran::evaluate::ArrayConstructor<Fortran::evaluate::Type<(Fortran::common::TypeCategory)1, 4> >, Fortran::evaluate::Designator<Fortran::evaluate::Type<(Fortran::common::TypeCategory)1, 4> >, Fortran::evaluate::FunctionRef<Fortran::evaluate::Type<(Fortran::common::TypeCategory)1, 4> > > const&>(Fortran::evaluate::Type<(Fortran::common::TypeCategory)1, 4>, std::__1::__variant_detail::__visitation::__variant::__value_visitor<fir::ExtendedValue (anonymous namespace)::ScalarExprLowering::genval<Fortran::evaluate::Type<(Fortran::common::TypeCategory)1, 4> >(Fortran::evaluate::Expr<Fortran::evaluate::Type<(Fortran::common::TypeCategory)1, 4> > const&)::'lambda'(Fortran::evaluate::Type<(Fortran::common::TypeCategory)1, 4> const&)>&&...) ConvertExpr.cpp:0:0
#15 0x00007ff16dbca986 decltype(auto) std::__1::__variant_detail::__visitation::__base::__dispatcher<2ul>::__dispatch<std::__1::__variant_detail::__visitation::__variant::__value_visitor<fir::ExtendedValue (anonymous namespace)::ScalarExprLowering::genval<Fortran::evaluate::SomeKind<(Fortran::common::TypeCategory)1> >(Fortran::evaluate::Expr<Fortran::evaluate::SomeKind<(Fortran::common::TypeCategory)1> > const&)::'lambda'(Fortran::evaluate::SomeKind<(Fortran::common::TypeCategory)1> const&)>&&, std::__1::__variant_detail::__base<(std::__1::__variant_detail::_Trait)1, Fortran::evaluate::Expr<Fortran::evaluate::Type<(Fortran::common::TypeCategory)1, 2> >, Fortran::evaluate::Expr<Fortran::evaluate::Type<(Fortran::common::TypeCategory)1, 3> >, Fortran::evaluate::Expr<Fortran::evaluate::Type<(Fortran::common::TypeCategory)1, 4> >, Fortran::evaluate::Expr<Fortran::evaluate::Type<(Fortran::common::TypeCategory)1, 8> >, Fortran::evaluate::Expr<Fortran::evaluate::Type<(Fortran::common::TypeCategory)1, 10> >, Fortran::evaluate::Expr<Fortran::evaluate::Type<(Fortran::common::TypeCategory)1, 16> > > const&>(Fortran::evaluate::SomeKind<(Fortran::common::TypeCategory)1>, std::__1::__variant_detail::__visitation::__variant::__value_visitor<fir::ExtendedValue (anonymous namespace)::ScalarExprLowering::genval<Fortran::evaluate::SomeKind<(Fortran::common::TypeCategory)1> >(Fortran::evaluate::Expr<Fortran::evaluate::SomeKind<(Fortran::common::TypeCategory)1> > const&)::'lambda'(Fortran::evaluate::SomeKind<(Fortran::common::TypeCategory)1> const&)>&&...) ConvertExpr.cpp:0:0
#16 0x00007ff16dc27ed1 fir::ExtendedValue (anonymous namespace)::ScalarExprLowering::genval<(Fortran::common::TypeCategory)0, 4, (Fortran::common::TypeCategory)1>(Fortran::evaluate::Convert<Fortran::evaluate::Type<(Fortran::common::TypeCategory)0, 4>, (Fortran::common::TypeCategory)1> const&) ConvertExpr.cpp:0:0
#17 0x00007ff16dc2659f decltype(auto) std::__1::__variant_detail::__visitation::__base::__dispatcher<9ul>::__dispatch<std::__1::__variant_detail::__visitation::__variant::__value_visitor<fir::ExtendedValue (anonymous namespace)::ScalarExprLowering::genval<Fortran::evaluate::Type<(Fortran::common::TypeCategory)0, 4> >(Fortran::evaluate::Expr<Fortran::evaluate::Type<(Fortran::common::TypeCategory)0, 4> > const&)::'lambda'(Fortran::evaluate::Type<(Fortran::common::TypeCategory)0, 4> const&)>&&, std::__1::__variant_detail::__base<(std::__1::__variant_detail::_Trait)1, Fortran::evaluate::Parentheses<Fortran::evaluate::Type<(Fortran::common::TypeCategory)0, 4> >, Fortran::evaluate::Negate<Fortran::evaluate::Type<(Fortran::common::TypeCategory)0, 4> >, Fortran::evaluate::Add<Fortran::evaluate::Type<(Fortran::common::TypeCategory)0, 4> >, Fortran::evaluate::Subtract<Fortran::evaluate::Type<(Fortran::common::TypeCategory)0, 4> >, Fortran::evaluate::Multiply<Fortran::evaluate::Type<(Fortran::common::TypeCategory)0, 4> >, Fortran::evaluate::Divide<Fortran::evaluate::Type<(Fortran::common::TypeCategory)0, 4> >, Fortran::evaluate::Power<Fortran::evaluate::Type<(Fortran::common::TypeCategory)0, 4> >, Fortran::evaluate::Extremum<Fortran::evaluate::Type<(Fortran::common::TypeCategory)0, 4> >, Fortran::evaluate::Convert<Fortran::evaluate::Type<(Fortran::common::TypeCategory)0, 4>, (Fortran::common::TypeCategory)0>, Fortran::evaluate::Convert<Fortran::evaluate::Type<(Fortran::common::TypeCategory)0, 4>, (Fortran::common::TypeCategory)1>, Fortran::evaluate::Constant<Fortran::evaluate::Type<(Fortran::common::TypeCategory)0, 4> >, Fortran::evaluate::ArrayConstructor<Fortran::evaluate::Type<(Fortran::common::TypeCategory)0, 4> >, Fortran::evaluate::Designator<Fortran::evaluate::Type<(Fortran::common::TypeCategory)0, 4> >, Fortran::evaluate::FunctionRef<Fortran::evaluate::Type<(Fortran::common::TypeCategory)0, 4> > > const&>(Fortran::evaluate::Type<(Fortran::common::TypeCategory)0, 4>, std::__1::__variant_detail::__visitation::__variant::__value_visitor<fir::ExtendedValue (anonymous namespace)::ScalarExprLowering::genval<Fortran::evaluate::Type<(Fortran::common::TypeCategory)0, 4> >(Fortran::evaluate::Expr<Fortran::evaluate::Type<(Fortran::common::TypeCategory)0, 4> > const&)::'lambda'(Fortran::evaluate::Type<(Fortran::common::TypeCategory)0, 4> const&)>&&...) ConvertExpr.cpp:0:0
#18 0x00007ff16dbc82b6 decltype(auto) std::__1::__variant_detail::__visitation::__base::__dispatcher<2ul>::__dispatch<std::__1::__variant_detail::__visitation::__variant::__value_visitor<fir::ExtendedValue (anonymous namespace)::ScalarExprLowering::genval<Fortran::evaluate::SomeKind<(Fortran::common::TypeCategory)0> >(Fortran::evaluate::Expr<Fortran::evaluate::SomeKind<(Fortran::common::TypeCategory)0> > const&)::'lambda'(Fortran::evaluate::SomeKind<(Fortran::common::TypeCategory)0> const&)>&&, std::__1::__variant_detail::__base<(std::__1::__variant_detail::_Trait)1, Fortran::evaluate::Expr<Fortran::evaluate::Type<(Fortran::common::TypeCategory)0, 1> >, Fortran::evaluate::Expr<Fortran::evaluate::Type<(Fortran::common::TypeCategory)0, 2> >, Fortran::evaluate::Expr<Fortran::evaluate::Type<(Fortran::common::TypeCategory)0, 4> >, Fortran::evaluate::Expr<Fortran::evaluate::Type<(Fortran::common::TypeCategory)0, 8> >, Fortran::evaluate::Expr<Fortran::evaluate::Type<(Fortran::common::TypeCategory)0, 16> > > const&>(Fortran::evaluate::SomeKind<(Fortran::common::TypeCategory)0>, std::__1::__variant_detail::__visitation::__variant::__value_visitor<fir::ExtendedValue (anonymous namespace)::ScalarExprLowering::genval<Fortran::evaluate::SomeKind<(Fortran::common::TypeCategory)0> >(Fortran::evaluate::Expr<Fortran::evaluate::SomeKind<(Fortran::common::TypeCategory)0> > const&)::'lambda'(Fortran::evaluate::SomeKind<(Fortran::common::TypeCategory)0> const&)>&&...) ConvertExpr.cpp:0:0
#19 0x00007ff16dbc0e76 decltype(auto) std::__1::__variant_detail::__visitation::__base::__dispatcher<4ul>::__dispatch<std::__1::__variant_detail::__visitation::__variant::__value_visitor<fir::ExtendedValue (anonymous namespace)::ScalarExprLowering::genval<Fortran::evaluate::SomeType>(Fortran::evaluate::Expr<Fortran::evaluate::SomeType> const&)::'lambda'(Fortran::evaluate::SomeType const&)>&&, std::__1::__variant_detail::__base<(std::__1::__variant_detail::_Trait)1, Fortran::evaluate::value::Integer<128, true, 32, unsigned int, unsigned long>, Fortran::evaluate::NullPointer, Fortran::evaluate::ProcedureDesignator, Fortran::evaluate::ProcedureRef, Fortran::evaluate::Expr<Fortran::evaluate::SomeKind<(Fortran::common::TypeCategory)0> >, Fortran::evaluate::Expr<Fortran::evaluate::SomeKind<(Fortran::common::TypeCategory)1> >, Fortran::evaluate::Expr<Fortran::evaluate::SomeKind<(Fortran::common::TypeCategory)2> >, Fortran::evaluate::Expr<Fortran::evaluate::SomeKind<(Fortran::common::TypeCategory)3> >, Fortran::evaluate::Expr<Fortran::evaluate::SomeKind<(Fortran::common::TypeCategory)4> >, Fortran::evaluate::Expr<Fortran::evaluate::SomeKind<(Fortran::common::TypeCategory)5> > > const&>(Fortran::evaluate::SomeType, std::__1::__variant_detail::__visitation::__variant::__value_visitor<fir::ExtendedValue (anonymous namespace)::ScalarExprLowering::genval<Fortran::evaluate::SomeType>(Fortran::evaluate::Expr<Fortran::evaluate::SomeType> const&)::'lambda'(Fortran::evaluate::SomeType const&)>&&...) ConvertExpr.cpp:0:0
#20 0x00007ff16dbbf5ee Fortran::lower::createSomeExtendedExpression(mlir::Location, Fortran::lower::AbstractConverter&, Fortran::evaluate::Expr<Fortran::evaluate::SomeType> const&, Fortran::lower::SymMap&, Fortran::lower::StatementContext&) (/home/ryuta/packages/llvm/flang/build/lib/libFortranLower.so.13git+0x2105ee)
#21 0x00007ff16db85446 decltype(auto) std::__1::__variant_detail::__visitation::__base::__dispatcher<0ul>::__dispatch<std::__1::__variant_detail::__visitation::__variant::__value_visitor<Fortran::common::visitors<(anonymous namespace)::FirConverter::genAssignment(Fortran::evaluate::Assignment const&)::'lambda'(Fortran::evaluate::Assignment::Intrinsic const&), (anonymous namespace)::FirConverter::genAssignment(Fortran::evaluate::Assignment const&)::'lambda'(Fortran::evaluate::ProcedureRef const&), (anonymous namespace)::FirConverter::genAssignment(Fortran::evaluate::Assignment const&)::'lambda'(std::__1::vector<Fortran::evaluate::Expr<Fortran::evaluate::Type<(Fortran::common::TypeCategory)0, 8> >, std::__1::allocator<Fortran::evaluate::Expr<Fortran::evaluate::Type<(Fortran::common::TypeCategory)0, 8> > > > const&), (anonymous namespace)::FirConverter::genAssignment(Fortran::evaluate::Assignment const&)::'lambda'(std::__1::vector<std::__1::pair<Fortran::evaluate::Expr<Fortran::evaluate::Type<(Fortran::common::TypeCategory)0, 8> >, Fortran::evaluate::Expr<Fortran::evaluate::Type<(Fortran::common::TypeCategory)0, 8> > >, std::__1::allocator<std::__1::pair<Fortran::evaluate::Expr<Fortran::evaluate::Type<(Fortran::common::TypeCategory)0, 8> >, Fortran::evaluate::Expr<Fortran::evaluate::Type<(Fortran::common::TypeCategory)0, 8> > > > > const&)> >&&, std::__1::__variant_detail::__base<(std::__1::__variant_detail::_Trait)1, Fortran::evaluate::Assignment::Intrinsic, Fortran::evaluate::ProcedureRef, std::__1::vector<Fortran::evaluate::Expr<Fortran::evaluate::Type<(Fortran::common::TypeCategory)0, 8> >, std::__1::allocator<Fortran::evaluate::Expr<Fortran::evaluate::Type<(Fortran::common::TypeCategory)0, 8> > > >, std::__1::vector<std::__1::pair<Fortran::evaluate::Expr<Fortran::evaluate::Type<(Fortran::common::TypeCategory)0, 8> >, Fortran::evaluate::Expr<Fortran::evaluate::Type<(Fortran::common::TypeCategory)0, 8> > >, std::__1::allocator<std::__1::pair<Fortran::evaluate::Expr<Fortran::evaluate::Type<(Fortran::common::TypeCategory)0, 8> >, Fortran::evaluate::Expr<Fortran::evaluate::Type<(Fortran::common::TypeCategory)0, 8> > > > > > const&>(std::__1::__variant_detail::__visitation::__variant::__value_visitor<Fortran::common::visitors<(anonymous namespace)::FirConverter::genAssignment(Fortran::evaluate::Assignment const&)::'lambda'(Fortran::evaluate::Assignment::Intrinsic const&), (anonymous namespace)::FirConverter::genAssignment(Fortran::evaluate::Assignment const&)::'lambda'(Fortran::evaluate::ProcedureRef const&), (anonymous namespace)::FirConverter::genAssignment(Fortran::evaluate::Assignment const&)::'lambda'(std::__1::vector<Fortran::evaluate::Expr<Fortran::evaluate::Type<(Fortran::common::TypeCategory)0, 8> >, std::__1::allocator<Fortran::evaluate::Expr<Fortran::evaluate::Type<(Fortran::common::TypeCategory)0, 8> > > > const&), (anonymous namespace)::FirConverter::genAssignment(Fortran::evaluate::Assignment const&)::'lambda'(std::__1::vector<std::__1::pair<Fortran::evaluate::Expr<Fortran::evaluate::Type<(Fortran::common::TypeCategory)0, 8> >, Fortran::evaluate::Expr<Fortran::evaluate::Type<(Fortran::common::TypeCategory)0, 8> > >, std::__1::allocator<std::__1::pair<Fortran::evaluate::Expr<Fortran::evaluate::Type<(Fortran::common::TypeCategory)0, 8> >, Fortran::evaluate::Expr<Fortran::evaluate::Type<(Fortran::common::TypeCategory)0, 8> > > > > const&)> >&&, std::__1::__variant_detail::__base<(std::__1::__variant_detail::_Trait)1, Fortran::evaluate::Assignment::Intrinsic, Fortran::evaluate::ProcedureRef, std::__1::vector<Fortran::evaluate::Expr<Fortran::evaluate::Type<(Fortran::common::TypeCategory)0, 8> >, std::__1::allocator<Fortran::evaluate::Expr<Fortran::evaluate::Type<(Fortran::common::TypeCategory)0, 8> > > >, std::__1::vector<std::__1::pair<Fortran::evaluate::Expr<Fortran::evaluate::Type<(Fortran::common::TypeCategory)0, 8> >, Fortran::evaluate::Expr<Fortran::evaluate::Type<(Fortran::common::TypeCategory)0, 8> > >, std::__1::allocator<std::__1::pair<Fortran::evaluate::Expr<Fortran::evaluate::Type<(Fortran::common::TypeCategory)0, 8> >, Fortran::evaluate::Expr<Fortran::evaluate::Type<(Fortran::common::TypeCategory)0, 8> > > > > > const&) Bridge.cpp:0:0
#22 0x00007ff16db85024 (anonymous namespace)::FirConverter::genAssignment(Fortran::evaluate::Assignment const&) Bridge.cpp:0:0
#23 0x00007ff16db7b0ee (anonymous namespace)::FirConverter::genFIR(Fortran::lower::pft::Evaluation&, bool) Bridge.cpp:0:0
#24 0x00007ff16db78721 (anonymous namespace)::FirConverter::lowerFunc(Fortran::lower::pft::FunctionLikeUnit&) Bridge.cpp:0:0
#25 0x00007ff16db73d58 Fortran::lower::LoweringBridge::lower(Fortran::parser::Program const&, Fortran::semantics::SemanticsContext const&) (/home/ryuta/packages/llvm/flang/build/lib/libFortranLower.so.13git+0x1c4d58)
#26 0x0000000000213955 main (/home/ryuta/packages/llvm/flang/build/bin/bbc+0x213955)
#27 0x00007ff16a071555 __libc_start_main (/lib64/libc.so.6+0x22555)
#28 0x000000000020f879 _start (/home/ryuta/packages/llvm/flang/build/bin/bbc+0x20f879)
@oroppas
Copy link
Author

oroppas commented May 22, 2021

AND with all BOZ typeless constant ended up with the same fatal error.

@jeanPerier
Copy link
Collaborator

AND is a GNU extension that is not recognized as an intrinsic by f18. So it dealt with as a user function, and lowering is not handling implicit function call with BOZ arguments (I did not expect BOZ arguments there given C7109 F2018 constraint (BOZ only allowed in DATA statement and where allowed as argument to intrinsic function)).

I will check what is the expected behavior for f18 here (if we should recognize and as an intrinsic. And if C7109 should be enforced or if lowering should support BOZ arguments to user function).

@vdonaldson vdonaldson changed the title bbc fatal internal error AND intrinsic [extension] with BOZ argument [additional extension] Jul 20, 2021
@vdonaldson vdonaldson added the enhancement New feature or request label Jul 20, 2021
psteinfeld added a commit to llvm/llvm-project that referenced this issue Jul 26, 2021
…faces

Since BOZ literal arguments are typeless, we cannot know how to pass them as
actual arguments to procedures with implicit interfaces.  This change avoids
the problem by emitting an error message in such situations.

This change stemmed from the following issue --
  flang-compiler#794

Differential Revision: https://reviews.llvm.org/D106831
@psteinfeld
Copy link
Collaborator

We should not be allowing BOZ arguments for procedures with implicit interfaces. This problem was fixed in https://reviews.llvm.org/D106831. With that change, bbc no longer crashes.

psteinfeld added a commit that referenced this issue Jul 28, 2021
…faces

Since BOZ literal arguments are typeless, we cannot know how to pass them as
actual arguments to procedures with implicit interfaces.  This change avoids
the problem by emitting an error message in such situations.

This change stemmed from the following issue --
  #794

Differential Revision: https://reviews.llvm.org/D106831
jeanPerier pushed a commit that referenced this issue Aug 4, 2021
…faces

Since BOZ literal arguments are typeless, we cannot know how to pass them as
actual arguments to procedures with implicit interfaces.  This change avoids
the problem by emitting an error message in such situations.

This change stemmed from the following issue --
  #794

Differential Revision: https://reviews.llvm.org/D106831
@oroppas
Copy link
Author

oroppas commented Aug 6, 2021

I can confirm #964 resolved the issue. This is now treated as semantic error.

@oroppas oroppas closed this as completed Aug 6, 2021
arichardson pushed a commit to CTSRD-CHERI/llvm-project that referenced this issue Sep 29, 2021
…faces

Since BOZ literal arguments are typeless, we cannot know how to pass them as
actual arguments to procedures with implicit interfaces.  This change avoids
the problem by emitting an error message in such situations.

This change stemmed from the following issue --
  flang-compiler/f18-llvm-project#794

Differential Revision: https://reviews.llvm.org/D106831
mleair pushed a commit that referenced this issue Oct 18, 2021
…faces

Since BOZ literal arguments are typeless, we cannot know how to pass them as
actual arguments to procedures with implicit interfaces.  This change avoids
the problem by emitting an error message in such situations.

This change stemmed from the following issue --
  #794

Differential Revision: https://reviews.llvm.org/D106831
jeanPerier pushed a commit that referenced this issue Oct 22, 2021
…faces

Since BOZ literal arguments are typeless, we cannot know how to pass them as
actual arguments to procedures with implicit interfaces.  This change avoids
the problem by emitting an error message in such situations.

This change stemmed from the following issue --
  #794

Differential Revision: https://reviews.llvm.org/D106831
mem-frob pushed a commit to draperlaboratory/hope-llvm-project that referenced this issue Oct 7, 2022
…faces

Since BOZ literal arguments are typeless, we cannot know how to pass them as
actual arguments to procedures with implicit interfaces.  This change avoids
the problem by emitting an error message in such situations.

This change stemmed from the following issue --
  flang-compiler/f18-llvm-project#794

Differential Revision: https://reviews.llvm.org/D106831
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

4 participants