Coder Social home page Coder Social logo

Comments (2)

AGSaidi avatar AGSaidi commented on August 19, 2024 2

The symbols you're searching for (e.g. __aarch64_cas4_acq_rel) are symbols used by -moutline-atomics to determine at run-time if a LSE (e.g. casal or a load-store exclusive e.g.ldaxr/stlxr are used)

0000000000400650 <__aarch64_cas4_acq_rel>:
  400650:	90000110 	adrp	x16, 420000 <getauxval@GLIBC_2.17>
  400654:	39409610 	ldrb	w16, [x16, #37]
  400658:	34000070 	cbz	w16, 400664 <__aarch64_cas4_acq_rel+0x14>
  40065c:	88e0fc41 	casal	w0, w1, [x2]
  400660:	d65f03c0 	ret
  400664:	2a0003f0 	mov	w16, w0
  400668:	885ffc40 	ldaxr	w0, [x2]
  40066c:	6b10001f 	cmp	w0, w16
  400670:	54000061 	b.ne	40067c <__aarch64_cas4_acq_rel+0x2c>  // b.any
  400674:	8811fc41 	stlxr	w17, w1, [x2]
  400678:	35ffff91 	cbnz	w17, 400668 <__aarch64_cas4_acq_rel+0x18>
  40067c:	d65f03c0 	ret

When you compile with -mno-outline-atomics or a compiler that didn't make -moutline-atomics the default and -march=armv8-a the compile will just inline the ldaxr/stlxr in the calling function the symbol you reference above won't be present. (note: GCC 7 in Amazon Linux2 includes back ported patches making -moutline-atomics the default.

When you compile with -march=armv8.2-a or with -mcpu=neoverse-n1 similarly a casal or other LSE atomic will simply be inlined in the caller instead of jumping to the symbols that come from libgcc which includes the above mentioned __aarcch64_* functions.

from aws-graviton-getting-started.

FranckPachot avatar FranckPachot commented on August 19, 2024

Thanks, got it.

from aws-graviton-getting-started.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.