Giter VIP home page Giter VIP logo

Comments (7)

chadaustin avatar chadaustin commented on August 18, 2024

There are several asm.js demos, so clearly function pointers work, but the spec doesn't mention them. So how do they work? :)

from validator.

kripken avatar kripken commented on August 18, 2024

Just like function pointers in emscripten in general - function pointers are indexes into a table of functions. There is a separate table for each function type though, mandated by asm.

from validator.

chadaustin avatar chadaustin commented on August 18, 2024

For each function type? Wow, why is that? That might make embind trickier.

Can you point me to where this is in the spec?

Sent from my iPhone

On Mar 25, 2013, at 3:29 PM, Alon Zakai [email protected] wrote:

Just like function pointers in emscripten in general - function pointers are indexes into a table of functions. There is a separate table for each function type though, mandated by asm.


Reply to this email directly or view it on GitHub.

from validator.

chadaustin avatar chadaustin commented on August 18, 2024

Hm, I think I understand why it's necessary to segregate function tables now. Indeed, this will make embind tricky, but I'll reach out directly when it's time to bring embind to asm.js.

Sent from my iPhone

On Mar 25, 2013, at 3:44 PM, Chad Austin [email protected] wrote:

For each function type? Wow, why is that? That might make embind trickier.

Can you point me to where this is in the spec?

Sent from my iPhone

On Mar 25, 2013, at 3:29 PM, Alon Zakai [email protected] wrote:

Just like function pointers in emscripten in general - function pointers are indexes into a table of functions. There is a separate table for each function type though, mandated by asm.


Reply to this email directly or view it on GitHub.

from validator.

 avatar commented on August 18, 2024

This is in the spec now.

from validator.

rntz avatar rntz commented on August 18, 2024

I've just looked at the asm.js spec at http://asmjs.org/spec/latest/#value-types , and there is no provision for function pointers as values. Why was this closed?

from validator.

sunfishcode avatar sunfishcode commented on August 18, 2024

What was added was support for function tables:

http://asmjs.org/spec/latest/#function-table-types

Function tables and indices thereinto can provide function-pointer functionality.

from validator.

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.