FAQ
I already have the various "wrapper versions" working perfectly with the
asm functions...

func asmFuncThing(...)
func (a *type) MethodThing(...) { asmFuncThing(...) }

...but I really want to skip the wrapper and call the assembler version as
the method. I've not seen any way to do this
and have about given up in trying, but before I do, I'll ask: do you know
how to do it?

Thanks if you know either way,
Michael
Michael T. Jones | Chief Technology Advocate | mtj@google.com | +1
650-335-5765

--
You received this message because you are subscribed to the Google Groups "golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Search Discussions

  • Dmitry Vyukov at Feb 22, 2013 at 6:27 am
    You can find some examples in runtime and sync/atomic std packages,
    look for *.s files.

    On Fri, Feb 22, 2013 at 9:06 AM, Michael Jones wrote:
    I already have the various "wrapper versions" working perfectly with the asm
    functions...

    func asmFuncThing(...)
    func (a *type) MethodThing(...) { asmFuncThing(...) }

    ...but I really want to skip the wrapper and call the assembler version as
    the method. I've not seen any way to do this
    and have about given up in trying, but before I do, I'll ask: do you know
    how to do it?

    Thanks if you know either way,
    Michael
    Michael T. Jones | Chief Technology Advocate | mtj@google.com | +1
    650-335-5765

    --
    You received this message because you are subscribed to the Google Groups
    "golang-nuts" group.
    To unsubscribe from this group and stop receiving emails from it, send an
    email to golang-nuts+unsubscribe@googlegroups.com.
    For more options, visit https://groups.google.com/groups/opt_out.
    --
    You received this message because you are subscribed to the Google Groups "golang-nuts" group.
    To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts+unsubscribe@googlegroups.com.
    For more options, visit https://groups.google.com/groups/opt_out.
  • Anthony Martin at Feb 22, 2013 at 7:01 am

    Michael Jones once said:
    I already have the various "wrapper versions" working perfectly with the
    asm functions...

    func asmFuncThing(...)
    func (a *type) MethodThing(...) { asmFuncThing(...) }

    ...but I really want to skip the wrapper and call the assembler version as
    the method. I've not seen any way to do this
    and have about given up in trying, but before I do, I'll ask: do you know
    how to do it?
    It's not possible. The assemblers don't allow
    the syntax that would be necessary for this:

    TEXT ·(*Type).MethodThing(SB), $0

    I don't think it would be that difficult to
    add, however. We'd have to special-case the
    first argument for the TEXT pseudo-instruction
    (and probably GLOBL and DATA).

    Anthony

    --
    You received this message because you are subscribed to the Google Groups "golang-nuts" group.
    To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts+unsubscribe@googlegroups.com.
    For more options, visit https://groups.google.com/groups/opt_out.
  • Rémy Oudompheng at Feb 22, 2013 at 8:16 am

    On 2013/2/22 Anthony Martin wrote:
    Michael Jones <mtj@google.com> once said:
    I already have the various "wrapper versions" working perfectly with the
    asm functions...

    func asmFuncThing(...)
    func (a *type) MethodThing(...) { asmFuncThing(...) }

    ...but I really want to skip the wrapper and call the assembler version as
    the method. I've not seen any way to do this
    and have about given up in trying, but before I do, I'll ask: do you know
    how to do it?
    It's not possible. The assemblers don't allow
    the syntax that would be necessary for this:

    TEXT ·(*Type).MethodThing(SB), $0

    I don't think it would be that difficult to
    add, however. We'd have to special-case the
    first argument for the TEXT pseudo-instruction
    (and probably GLOBL and DATA).
    Maybe simply allow quoted strings instead of adding a special case?
    Like
    TEXT "·(*Type).MethodThing"(SB), 7, $0

    Rémy.

    --
    You received this message because you are subscribed to the Google Groups "golang-nuts" group.
    To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts+unsubscribe@googlegroups.com.
    For more options, visit https://groups.google.com/groups/opt_out.
  • Michael Jones at Feb 22, 2013 at 8:21 am
    Good suggestion. I was just looking at "6a" and pondering options. Seems
    silly to have such a lapse if it is indeed no more than passing a string
    through.

    On Fri, Feb 22, 2013 at 12:16 AM, Rémy Oudompheng
    wrote:
    On 2013/2/22 Anthony Martin wrote:
    Michael Jones <mtj@google.com> once said:
    I already have the various "wrapper versions" working perfectly with the
    asm functions...

    func asmFuncThing(...)
    func (a *type) MethodThing(...) { asmFuncThing(...) }

    ...but I really want to skip the wrapper and call the assembler version
    as
    the method. I've not seen any way to do this
    and have about given up in trying, but before I do, I'll ask: do you
    know
    how to do it?
    It's not possible. The assemblers don't allow
    the syntax that would be necessary for this:

    TEXT ·(*Type).MethodThing(SB), $0

    I don't think it would be that difficult to
    add, however. We'd have to special-case the
    first argument for the TEXT pseudo-instruction
    (and probably GLOBL and DATA).
    Maybe simply allow quoted strings instead of adding a special case?
    Like
    TEXT "·(*Type).MethodThing"(SB), 7, $0

    Rémy.


    --
    Michael T. Jones | Chief Technology Advocate | mtj@google.com | +1
    650-335-5765

    --
    You received this message because you are subscribed to the Google Groups "golang-nuts" group.
    To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts+unsubscribe@googlegroups.com.
    For more options, visit https://groups.google.com/groups/opt_out.

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
groupgolang-nuts @
categoriesgo
postedFeb 22, '13 at 5:07a
activeFeb 22, '13 at 8:21a
posts5
users4
websitegolang.org

People

Translate

site design / logo © 2022 Grokbase