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 8495151
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 10, 20262026-06-10T23:29:30+00:00 2026-06-10T23:29:30+00:00

Is it possible to force gcc to store an array in a specific segment?

  • 0

Is it possible to force gcc to store an array in a specific segment?

I want this

static const Host_Vtable_Entrty Host_vtable[]=
{
{"Window_create",(Function)Window_create}
,{"Window_cropEllipse",(Function)Window_cropEllipse}
,{"Window_cropRect",(Function)Window_cropRect}
,{"Window_cropRectRound",(Function)Window_cropRectRound}
,{"Window_destroy",(Function)Window_destroy}
,{"Window_filenameGet",(Function)Window_filenameGet}
,{"Window_filenameGet",(Function)Window_messageBox}
,{"Window_move",(Function)Window_move}
,{"Window_styleSet",(Function)Window_styleSet}
};

To be stored in a read-only place, but it is put in the data segment:

    .data
.align 32
_ZL11Host_vtable:
.quad   .LC0
.quad   _Z13Window_createP6WindowP6ObjectPFyS2_PjyyEPFyS2_yPvE
.quad   .LC1
.quad   _Z18Window_cropEllipseP6Windowjdddd
.quad   .LC2
.quad   _Z15Window_cropRectP6Windowjdddd
.quad   .LC3
.quad   _Z20Window_cropRectRoundP6Windowjdddddd
.quad   .LC4
.quad   _Z14Window_destroyP6Window
.quad   .LC5
.quad   _Z18Window_filenameGetPcyPKcS1_j
.quad   .LC5
.quad   _Z17Window_messageBoxP6WindowPKcS2_j
.quad   .LC6
.quad   _Z11Window_moveP6Windowdddd
.quad   .LC7
.quad   _Z15Window_styleSetP6Windowjj

Do I need to write the assembly manually?

  • 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-06-10T23:29:32+00:00Added an answer on June 10, 2026 at 11:29 pm

    If you search the GCC documentation for GCC-specific extensions to the language, you will stumble upon a document describing variable attributes. Here you will find one attribute called segment with examples on how to use it.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

this may be a very simple question, but is it possible to force a
> return $this->_prepareDownloadResponse( > 'invoice'.Mage::getSingleton('core/date')->date('Y-m-d_H-i-s').'.pdf', > $pdf->render(), 'application/pdf' Is it still possible to force
Possible Duplicate: Force Download an Image Using Javascript Basically I want to have the
Is it possible to force gcc use int instruction for all the system calls,
Is it possible force the browser to fresh the cached CSS? This is not
Is it possible to programmatically break into debugger from GCC? For example I want
Is it possible to force case-sensitive for a query? Mine sounds like this: SELECT
Is it possible to force the iPhone to shutdown ( programmatically , of course)?
Is it possible to force the Facebook session to refresh, or alternatively, call the
I'm wondering if it is possible to force an Open/Save dialog for an inline

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.