Bug 199554

Summary: clang assembler generates errors for .uleb128
Product: Base System Reporter: Sean Bruno <sbruno>
Component: armAssignee: freebsd-arm (Nobody) <freebsd-arm>
Status: Closed FIXED    
Severity: Affects Some People CC: dim
Priority: ---    
Version: CURRENT   
Hardware: arm   
OS: Any   
URL: http://chips.ysv.freebsd.org/data/11armv6hf-default/2015-04-19_22h30m33s/logs/errors/texlive-base-20140525_6.log

Description Sean Bruno freebsd_committer freebsd_triage 2015-04-20 02:52:27 UTC
I'm guessing that GAS understands the ARM assembly directive:

.uleb128 94, 10

Clang --integrated-as does not:

lj_vm_asm.s:2653:13: error: unexpected token in directive
        .uleb128 94, 10
Comment 1 Dimitry Andric freebsd_committer freebsd_triage 2015-04-20 07:05:37 UTC
Support for this rather fuzzy syntax is added by upstream commit:
http://llvm.org/viewvc/llvm-project?view=revision&revision=229911

I will import this shortly, and it's also scheduled for the llvm/clang 3.6.1 release.
Comment 2 commit-hook freebsd_committer freebsd_triage 2015-04-20 17:36:39 UTC
A commit references this bug:

Author: dim
Date: Mon Apr 20 17:36:35 UTC 2015
New revision: 281775
URL: https://svnweb.freebsd.org/changeset/base/281775

Log:
  Pull in r229911 from upstream llvm trunk (by Benjamin Kramer):

    MC: Allow multiple comma-separated expressions on the .uleb128 directive.

    For compatiblity with GNU as. Binutils documents this as
    '.uleb128 expressions'. Subtle, isn't it?

  Reported by:	sbruno
  PR:		199554
  MFC after:	3 days

Changes:
  head/contrib/llvm/lib/MC/MCParser/AsmParser.cpp
Comment 3 Sean Bruno freebsd_committer freebsd_triage 2015-04-21 02:59:22 UTC
http://crack.ysv.freebsd.org/data/11armv6hf-default/2015-04-20_22h58m04s/logs/texlive-base-20140525_6.log

Looks good from here.

If you want to close this out, I'm good.
Comment 4 commit-hook freebsd_committer freebsd_triage 2015-04-23 22:06:06 UTC
A commit references this bug:

Author: dim
Date: Thu Apr 23 22:06:03 UTC 2015
New revision: 281908
URL: https://svnweb.freebsd.org/changeset/base/281908

Log:
  MFC r281775:

  Pull in r229911 from upstream llvm trunk (by Benjamin Kramer):

    MC: Allow multiple comma-separated expressions on the .uleb128 directive.

    For compatiblity with GNU as. Binutils documents this as
    '.uleb128 expressions'. Subtle, isn't it?

  Reported by:	sbruno
  PR:		199554

  MFC r281777:

  Add llvm patch corresponding to r281775.

Changes:
_U  stable/10/
  stable/10/contrib/llvm/lib/MC/MCParser/AsmParser.cpp
  stable/10/contrib/llvm/patches/patch-r281775-llvm-r229911-uleb128-commas.diff
_U  stable/9/contrib/llvm/
  stable/9/contrib/llvm/lib/MC/MCParser/AsmParser.cpp
  stable/9/contrib/llvm/patches/patch-r281775-llvm-r229911-uleb128-commas.diff