Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6125503
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T16:15:20+00:00 2026-05-23T16:15:20+00:00

What is vftable in high programming languages? I read something like it’s the address

  • 0

What is vftable in high programming languages?

I read something like it’s the address of a virtual object structure, but this is a pretty messy information

Can someone please explain it?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-23T16:15:21+00:00Added an answer on May 23, 2026 at 4:15 pm

    It most likely stands for “Virtual Function Table“, and is a mechanism used by some runtime implementations in order to allow virtual function dispatch.

    Mainstream C++ implementations (GCC, Clang, MSVS) call it the vtable. C has no polymorphism. I could only speculate about other languages.


    Here’s what Wikipedia says on the topic:

    An object’s dispatch table will contain the addresses of the object’s
    dynamically bound methods. Method calls are performed by fetching the
    method’s address from the object’s dispatch table. The dispatch table
    is the same for all objects belonging to the same class, and is
    therefore typically shared between them. Objects belonging to
    type-compatible classes (for example siblings in an inheritance
    hierarchy) will have dispatch tables with the same layout: the address
    of a given method will appear at the same offset for all
    type-compatible classes. Thus, fetching the method’s address from a
    given dispatch table offset will get the method corresponding to the
    object’s actual class.[1]

    The C++ standards do not mandate exactly how dynamic dispatch must be
    implemented, but compilers generally use minor variations on the same
    basic model.

    Typically, the compiler creates a separate vtable for each class. When
    an object is created, a pointer to this vtable, called the virtual
    table pointer, vpointer or VPTR, is added as a hidden member of this
    object (becoming its first member unless it’s made the last[2]). The
    compiler also generates “hidden” code in the constructor of each class
    to initialize the vpointers of its objects to the address of the
    corresponding vtable. Note that the location of the vpointer in the
    object instance is not standard among all compilers, and relying on
    the position may result in unportable code. For example, g++
    previously placed the vpointer at the end of the object.[3]

    1. Ellis & Stroustrup 1990, pp. 227–232
    2. Heading “Multiple Inheritance”
    3. CodeSourcery C++ ABI
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

If we write virtual function it adds a vtable in object of that class.
I have a model called Vote and this is what vote.rb looks like: class
We all know what virtual functions are in C++, but how are they implemented
This is probably habitual programming redundancy. I have noticed DECLSPEC_NOVTABLE ( __declspec(novtable) ) on
I think I understand the concept of virtual methods and vtables, but I don't
Now and then when using GCC I get cryptic errors like this: undefined reference
I need to get the front-most address of a complete object even if what
Is it essential to have a definition for a virtual function? Consider this sample
I heard lots of times virtual function is usually implemented using a vtable. But
I need to call the co-class function by reading its address from vtable of

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.