GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — Error : Verify Failed , when using --fast · Issue #1668 · lcompilers/lpython

Error : Verify Failed , when using --fast #1668

New issue
Copy link
New issue
Copy link
Closed
#1688
Closed
Error : Verify Failed , when using --fast#1668
#1688
Copy link
Labels
bugSomething isn't workingSomething isn't working

Description

@sarthakgupta0
sarthakgupta0
opened on Apr 5, 2023
Issue body actions

Came across this error when trying out benchmarks. Error occurs only when compiling with the --fast optimization.

def func() -> i32:
     return 30

def test() -> i32:
    temp: i32 = func()
    return temp

x : i32 
x = test()
print(x)
(lp) sarthak@pop-os:~/lpython$ lpython examples/test.py
30
(lp) sarthak@pop-os:~/lpython$ lpython --fast examples/test.py
ASR verify pass error: ASR verify: Block ~empty_block should resolve in current scope.
Internal Compiler Error: Unhandled exception
Traceback (most recent call last):
  Binary file "/home/sarthak/lpython/src/bin/lpython", in _start()
  File "./csu/../csu/libc-start.c", line 392, in __libc_start_main_impl()
  File "./csu/../sysdeps/nptl/libc_start_call_main.h", line 58, in __libc_start_call_main()
  File "/home/sarthak/lpython/src/bin/lpython.cpp", line 1750, in ??
    err = compile_python_to_object_file(arg_file, tmp_o, runtime_library_dir,
  File "/home/sarthak/lpython/src/bin/lpython.cpp", line 750, in ??
    res = fe.get_llvm3(*asr, pass_manager, diagnostics, infile);
  File "/home/sarthak/lpython/src/lpython/python_evaluator.cpp", line 58, in LCompilers::PythonCompiler::get_llvm3(LCompilers::ASR::TranslationUnit_t&, LCompilers::PassManager&, LCompilers::diag::Diagnostics&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)
    run_fn, infile);
  File "/home/sarthak/lpython/src/libasr/codegen/asr_to_llvm.cpp", line 7027, in LCompilers::asr_to_llvm(LCompilers::ASR::TranslationUnit_t&, LCompilers::diag::Diagnostics&, llvm::LLVMContext&, Allocator&, LCompilers::PassManager&, LCompilers::CompilerOptions&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)
    pass_manager.apply_passes(al, &asr, pass_options, diagnostics);
  File "/home/sarthak/lpython/src/libasr/pass/pass_manager.h", line 214, in LCompilers::PassManager::apply_passes(Allocator&, LCompilers::ASR::TranslationUnit_t*, LCompilers::PassOptions&, LCompilers::diag::Diagnostics&)
    _apply_passes(al, asr, _with_optimization_passes, pass_options,
LCompilersException: Verify failed

Activity

  1. certik
    added
    bugSomething isn't workingSomething isn't working
    on Apr 5, 2023
  2. certik commented on Apr 5, 2023

    @certik
    certik
    on Apr 5, 2023
    Contributor
    More actions

    Thanks for reporting it, I added this to #1600. I think we need to start testing with --fast in our integration_tests to catch this earlier (#1669).

    Reacted by Thirumalai Shaktivel
  3. Thirumalai-Shaktivel
    closed this as completedin #1688on Apr 18, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingSomething isn't working

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

      You are visitor 01402503 — GeezerVison does not store the pages you look up.
      Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.