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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 7, 20262026-06-07T12:40:42+00:00 2026-06-07T12:40:42+00:00

What is the size of a process/thread in Linux? When a process/thread is created,

  • 0

What is the size of a process/thread in Linux? When a process/thread is created, along with task_struct and other data structure inside it, is there anything else?

Is the stack of a process/thread allocated upon process/thread initialization (fixed size)? Or is it allocated when necessary (like virtual memory)?

How can I know what size a standard process/thread when it is created in memory?

  • 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-07T12:40:44+00:00Added an answer on June 7, 2026 at 12:40 pm

    When a large block of memory (> pagesize = 4096 bytes) is first allocated on Linux it uses special “null” memory pages in the pagetable that aren’t backed by anything, so when a thread is started it will allocate ~1 MB of these zero pages for a thread stack. As the stack grows the pages are then converted into real memory backed pages. Because of this “null” page backing it is generally okay to have liberally large stacks.

    Threads and processes are both created with the same underlying syscall called clone(2). It has lots of options and does lots of stuff. see man clone for a detailed explanation.

    http://linux.die.net/man/2/clone

    Large blocks of memory are allocated with an anonymous mmap(2) call.

    You may also be interested in doing a web search for “linux overcommit bit”

    (If you want to refine your question, I can be more specific.)

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

Sidebar

Related Questions

The size of a class with no data members is returned as 1 byte,
I'm trying to accomplish the following: Have a thread that reads data from a
i am using a ThreadPoolExecutor with a thread pool size of one to sequentially
What is the relationship between ulimit -s <value > and the stack size (at
I need to read from NetworkStream which would send data randomly and the size
I have a high-priority process that needs to pass data to a low-priority process.
Suppose we have many user processes running on Linux. Each process has many threads
I'm in the process of writing a template library for data-caching in C++ where
I am trying to process millions of records from my table (size is about
everyone... I've just started to learn how to create process and thread using Windows

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.