Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt
  • Unsolved
Collapse
qtws26_logo

The Qt Event of the Year: Qt World Summit 2026

Save Your Spot >
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. QProcess created in another app: Would they share the stack ?
Qt 6.12 LTS is out! See what's new in the release blog

QProcess created in another app: Would they share the stack ?

Scheduled Pinned Locked Moved Solved General and Desktop
5 Posts 3 Posters 882 Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • Q Offline
    Q Offline
    QBst
    wrote on last edited by QBst
    #1

    Hello everyone,
    When a QProcess is created in another application (QProcess() called w/o parent means it wouldnt be started as a child process, but as a parallel one, right?) would they share the stack? Do we need to take care with sigaction and SA_ONSTACK ?

    JonBJ 1 Reply Last reply
    0
    • Q QBst

      Would they share the stack, when created as a child process (w. parent parameter: QProcess(parent) )?

      jsulmJ Offline
      jsulmJ Offline
      jsulm
      Lifetime Qt Champion
      wrote on last edited by
      #5

      @QBst Different processes never share stack! Doesn't matter how they were started. Even heap memory is not shared. You need to use "shared memory" to share memory between processes.

      https://forum.qt.io/topic/113070/qt-code-of-conduct

      1 Reply Last reply
      1
      • Q QBst

        Hello everyone,
        When a QProcess is created in another application (QProcess() called w/o parent means it wouldnt be started as a child process, but as a parallel one, right?) would they share the stack? Do we need to take care with sigaction and SA_ONSTACK ?

        JonBJ Offline
        JonBJ Offline
        JonB
        wrote on last edited by JonB
        #2

        @QBst
        Hello and welcome.

        No, they are separate processes, no "stack sharing". QProcess just runs an external process.

        JonBJ 1 Reply Last reply
        1
        • Q Offline
          Q Offline
          QBst
          wrote on last edited by
          #3

          Would they share the stack, when created as a child process (w. parent parameter: QProcess(parent) )?

          jsulmJ 1 Reply Last reply
          0
          • JonBJ JonB

            @QBst
            Hello and welcome.

            No, they are separate processes, no "stack sharing". QProcess just runs an external process.

            JonBJ Offline
            JonBJ Offline
            JonB
            wrote on last edited by
            #4

            @JonB said in QProcess created in another app: Would they share the stack ?:

            No, they are separate processes, no "stack sharing".

            Is that 100% clear? :) parent parameter is to do with Qt's object-ownership hierarchy, nothing to do with sub-process parentage. Sub-process parent will be the Qt program. And still no kind of "stack sharing" :)

            1 Reply Last reply
            0
            • Q QBst

              Would they share the stack, when created as a child process (w. parent parameter: QProcess(parent) )?

              jsulmJ Offline
              jsulmJ Offline
              jsulm
              Lifetime Qt Champion
              wrote on last edited by
              #5

              @QBst Different processes never share stack! Doesn't matter how they were started. Even heap memory is not shared. You need to use "shared memory" to share memory between processes.

              https://forum.qt.io/topic/113070/qt-code-of-conduct

              1 Reply Last reply
              1

              • Login

              • Login or register to search.
              • First post
                Last post
              0
              • Categories
              • Recent
              • Tags
              • Popular
              • Users
              • Groups
              • Search
              • Get Qt
              • Unsolved