<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugs.webkit.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.4.1"
          urlbase="https://bugs.webkit.org/"
          
          maintainer="admin@webkit.org"
>

    <bug>
          <bug_id>274826</bug_id>
          
          <creation_ts>2024-05-29 05:04:01 -0700</creation_ts>
          <short_desc>[GTK] [2.45.3] riscv: LowLevelInterpreter.cpp:610:78: error: expected ‘)’ before ‘OFFLINE_ASM_ALIGN_TRAP’</short_desc>
          <delta_ts>2024-12-11 15:13:13 -0800</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>WebKit</product>
          <component>WebKitGTK</component>
          <version>WebKit Nightly Build</version>
          <rep_platform>Unspecified</rep_platform>
          <op_sys>Unspecified</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P2</priority>
          <bug_severity>Normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Alberto Garcia">berto</reporter>
          <assigned_to name="Nobody">webkit-unassigned</assigned_to>
          <cc>bugs-noreply</cc>
    
    <cc>emcifuntik</cc>
    
    <cc>mcatanzaro</cc>
    
    <cc>michael</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>2038421</commentid>
    <comment_count>0</comment_count>
    <who name="Alberto Garcia">berto</who>
    <bug_when>2024-05-29 05:04:01 -0700</bug_when>
    <thetext>In file included from /home/berto/webkit2gtk-2.45.3/Source/JavaScriptCore/assembler/MacroAssembler.h:81,
                 from /home/berto/webkit2gtk-2.45.3/Source/JavaScriptCore/jit/Reg.h:30,
                 from /home/berto/webkit2gtk-2.45.3/Source/JavaScriptCore/jit/RegisterAtOffset.h:30,
                 from /home/berto/webkit2gtk-2.45.3/Source/JavaScriptCore/jit/RegisterAtOffsetList.h:30,
                 from /home/berto/webkit2gtk-2.45.3/Source/JavaScriptCore/wasm/WasmCallee.h:32,
                 from /home/berto/webkit2gtk-2.45.3/Source/JavaScriptCore/llint/LowLevelInterpreter.cpp:633:
/home/berto/webkit2gtk-2.45.3/Source/JavaScriptCore/assembler/MacroAssemblerRISCV64.h: In member function ‘void JSC::MacroAssemblerRISCV64::testFinalize(ResultCondition, JSC::AbstractMacroAssembler&lt;JSC::RISCV64Assembler&gt;::RegisterID, JSC::AbstractMacroAssembler&lt;JSC::RISCV64Assembler&gt;::RegisterID)’:
/home/berto/webkit2gtk-2.45.3/Source/JavaScriptCore/assembler/MacroAssemblerRISCV64.h:4463:16: warning: enumeration value ‘Carry’ not handled in switch [-Wswitch]
 4463 |         switch (cond) {
      |                ^
/home/berto/webkit2gtk-2.45.3/build-soup3/JavaScriptCore/DerivedSources/LLIntAssembly.h: At global scope:
/home/berto/webkit2gtk-2.45.3/Source/JavaScriptCore/llint/LowLevelInterpreter.cpp:610:78: error: expected ‘)’ before ‘OFFLINE_ASM_ALIGN_TRAP’
  610 |     OFFLINE_ASM_GLOBAL_LABEL_IMPL(label, OFFLINE_ASM_NO_ALT_ENTRY_DIRECTIVE, OFFLINE_ASM_ALIGN_TRAP(align), HIDE_SYMBOL)
      |                                                                              ^~~~~~~~~~~~~~~~~~~~~~
/home/berto/webkit2gtk-2.45.3/Source/JavaScriptCore/llint/LowLevelInterpreter.cpp:573:5: note: in definition of macro ‘OFFLINE_ASM_GLOBAL_LABEL_IMPL’
  573 |     ALIGNMENT                                   \
      |     ^~~~~~~~~
/home/berto/webkit2gtk-2.45.3/build-soup3/JavaScriptCore/DerivedSources/LLIntAssembly.h:104463:1: note: in expansion of macro ‘OFFLINE_ASM_ALIGNED_GLOBAL_LABEL’
104463 | OFFLINE_ASM_ALIGNED_GLOBAL_LABEL(ipint_unreachable_validate, 256)
       | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2065689</commentid>
    <comment_count>1</comment_count>
    <who name="Andreas Schwab">schwab</who>
    <bug_when>2024-10-05 14:22:38 -0700</bug_when>
    <thetext>+#elif CPU(RISCV64)
+#define OFFLINE_ASM_ALIGN_TRAP(align) OFFLINE_ASM_BEGIN_SPACER &quot;\n .balignw &quot; #align &quot;, 0x9002\n&quot; // pad with c.ebreak instructions</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2065694</commentid>
    <comment_count>2</comment_count>
    <who name="Alberto Garcia">berto</who>
    <bug_when>2024-10-05 16:57:06 -0700</bug_when>
    <thetext>That does not seem to be enough:

In file included from webkit2gtk-2.46.1/Source/JavaScriptCore/assembler/MacroAssembler.h:81,
                 from webkit2gtk-2.46.1/Source/JavaScriptCore/jit/GPRInfo.h:28,
                 from webkit2gtk-2.46.1/Source/JavaScriptCore/bytecode/ArithProfile.h:28,
                 from webkit2gtk-2.46.1/Source/JavaScriptCore/llint/LLIntOffsetsExtractor.cpp:28:
webkit2gtk-2.46.1/Source/JavaScriptCore/assembler/MacroAssemblerRISCV64.h: In member function ‘void JSC::MacroAssemblerRISCV64::testFinalize(ResultCondition, JSC::AbstractMacroAssembler&lt;JSC::RISCV64Assembler&gt;::RegisterID, JSC::AbstractMacroAssembler&lt;JSC::RISCV64Assembler&gt;::RegisterID)’:
webkit2gtk-2.46.1/Source/JavaScriptCore/assembler/MacroAssemblerRISCV64.h:4508:16: warning: enumeration value ‘Carry’ not handled in switch [-Wswitch]
 4508 |         switch (cond) {
      |                ^
webkit2gtk-2.46.1/Source/JavaScriptCore/jit/GPRInfo.h: At global scope:
webkit2gtk-2.46.1/Source/JavaScriptCore/jit/GPRInfo.h:759:38: error: ‘RICSV64Registers’ has not been declared
  759 |     static constexpr GPRReg regWS0 = RICSV64Registers::x6;
      |                                      ^~~~~~~~~~~~~~~~
webkit2gtk-2.46.1/Source/JavaScriptCore/jit/GPRInfo.h:760:38: error: ‘RICSV64Registers’ has not been declared
  760 |     static constexpr GPRReg regWS1 = RICSV64Registers::x7;
      |                                      ^~~~~~~~~~~~~~~~
webkit2gtk-2.46.1/Source/JavaScriptCore/jit/GPRInfo.h:761:38: error: ‘RICSV64Registers’ has not been declared
  761 |     static constexpr GPRReg regWA0 = RICSV64Registers::x10;
      |                                      ^~~~~~~~~~~~~~~~
webkit2gtk-2.46.1/Source/JavaScriptCore/jit/GPRInfo.h:762:38: error: ‘RICSV64Registers’ has not been declared
  762 |     static constexpr GPRReg regWA1 = RICSV64Registers::x11;
      |                                      ^~~~~~~~~~~~~~~~
webkit2gtk-2.46.1/Source/JavaScriptCore/jit/GPRInfo.h:763:38: error: ‘RICSV64Registers’ has not been declared
  763 |     static constexpr GPRReg regWA2 = RICSV64Registers::x12;
      |                                      ^~~~~~~~~~~~~~~~
webkit2gtk-2.46.1/Source/JavaScriptCore/jit/GPRInfo.h:764:38: error: ‘RICSV64Registers’ has not been declared
  764 |     static constexpr GPRReg regWA3 = RICSV64Registers::x13;
      |                                      ^~~~~~~~~~~~~~~~
webkit2gtk-2.46.1/Source/JavaScriptCore/jit/GPRInfo.h:765:38: error: ‘RICSV64Registers’ has not been declared
  765 |     static constexpr GPRReg regWA4 = RICSV64Registers::x14;
      |                                      ^~~~~~~~~~~~~~~~
webkit2gtk-2.46.1/Source/JavaScriptCore/jit/GPRInfo.h:766:38: error: ‘RICSV64Registers’ has not been declared
  766 |     static constexpr GPRReg regWA5 = RICSV64Registers::x15;
      |                                      ^~~~~~~~~~~~~~~~
webkit2gtk-2.46.1/Source/JavaScriptCore/jit/GPRInfo.h:767:38: error: ‘RICSV64Registers’ has not been declared
  767 |     static constexpr GPRReg regWA6 = RICSV64Registers::x16;
      |                                      ^~~~~~~~~~~~~~~~
webkit2gtk-2.46.1/Source/JavaScriptCore/jit/GPRInfo.h:768:38: error: ‘RICSV64Registers’ has not been declared
  768 |     static constexpr GPRReg regWA7 = RICSV64Registers::x17;
      |                                      ^~~~~~~~~~~~~~~~</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2069670</commentid>
    <comment_count>3</comment_count>
    <who name="Andreas Schwab">schwab</who>
    <bug_when>2024-10-21 14:57:37 -0700</bug_when>
    <thetext>https://bugs.webkit.org/show_bug.cgi?id=281380</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2069789</commentid>
    <comment_count>4</comment_count>
    <who name="Alberto Garcia">berto</who>
    <bug_when>2024-10-22 04:18:52 -0700</bug_when>
    <thetext>Oh, I see. With that and your patch from comment #1 it gets a bit better but I still cannot make it build:

FAILED: JavaScriptCore/DerivedSources/LLIntDesiredOffsets.h /home/berto/webkit2gtk-2.46.2/build-soup3/JavaScriptCore/DerivedSources/LLIntDesiredOffsets.h 
cd /home/berto/webkit2gtk-2.46.2/build-soup3/Source/JavaScriptCore &amp;&amp; /usr/bin/ruby /home/berto/webkit2gtk-2.46.2/Source/JavaScriptCore/offlineasm/generate_offset_extractor.rb -I/home/berto/webkit2gtk-2.46.2/build-soup3/JavaScriptCore/DerivedSources/ /home/berto/webkit2gtk-2.46.2/Source/JavaScriptCore/llint/LowLevelInterpreter.asm /home/berto/webkit2gtk-2.46.2/build-soup3/bin/LLIntSettingsExtractor /home/berto/webkit2gtk-2.46.2/build-soup3/JavaScriptCore/DerivedSources/LLIntDesiredOffsets.h C_LOOP normal
LowLevelInterpreter.asm:2738 in call to entry: Could not find macro entry (MacroError)
ninja: build stopped: subcommand failed.

This is webkitgtk 2.46.2 and I&apos;m using -DENABLE_JIT=OFF -DENABLE_WEBASSEMBLY=OFF</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2075047</commentid>
    <comment_count>5</comment_count>
    <who name="Michael Orlitzky">michael</who>
    <bug_when>2024-11-14 06:31:38 -0800</bug_when>
    <thetext>*** Bug 281138 has been marked as a duplicate of this bug. ***</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2075049</commentid>
    <comment_count>6</comment_count>
    <who name="Michael Orlitzky">michael</who>
    <bug_when>2024-11-14 06:36:09 -0800</bug_when>
    <thetext>This _particular_ error was fixed by https://github.com/WebKit/WebKit/pull/36458

If you check the recent open/closed PRs on Github with &quot;riscv&quot; in the name, there are several others in the pipeline to fix riscv build failures (thanks to MingZhu Yan).</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2080640</commentid>
    <comment_count>7</comment_count>
    <who name="Michael Catanzaro">mcatanzaro</who>
    <bug_when>2024-12-10 14:45:06 -0800</bug_when>
    <thetext>(In reply to Michael Orlitzky from comment #6)
&gt; This _particular_ error was fixed by
&gt; https://github.com/WebKit/WebKit/pull/36458

Thanks for flagging this.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2080976</commentid>
    <comment_count>8</comment_count>
    <who name="EWS">ews-feeder</who>
    <bug_when>2024-12-11 15:13:13 -0800</bug_when>
    <thetext>Committed 287700@main (23ae044647e7): &lt;https://commits.webkit.org/287700@main&gt;

Reviewed commits have been landed. Closing PR #37767 and removing active labels.</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>