Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Out of Memory

Out of Memory

Scheduled Pinned Locked Moved Unsolved General and Desktop
5 Posts 3 Posters 971 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.
  • M Offline
    M Offline
    mahd96
    wrote on 9 Jun 2019, 09:09 last edited by mahd96 6 Sept 2019, 09:10
    #1

    windows stop allocating memory to my app after 1.7G memory usage. i have allocated some page file. but it seemed to not working because i have some logs that indicates appliucation is out of memory:
    QImage :: out of memory return null
    QPainter :: can not start ...
    QThread :: start() :: can not start
    and after these whenever a signal emits application crashs!
    what can i do before i optimize my memory usage that i decrease this crashes?

    J 1 Reply Last reply 9 Jun 2019, 10:59
    0
    • M Offline
      M Offline
      mrjj
      Lifetime Qt Champion
      wrote on 9 Jun 2019, 09:13 last edited by
      #2

      Hi
      Is it a 32 bit app ?
      What platform are you running it on ? also 32 bit ?
      There is hard limit of 32 bit of around 2GB and you might be hitting that.

      M 1 Reply Last reply 9 Jun 2019, 09:46
      3
      • M mrjj
        9 Jun 2019, 09:13

        Hi
        Is it a 32 bit app ?
        What platform are you running it on ? also 32 bit ?
        There is hard limit of 32 bit of around 2GB and you might be hitting that.

        M Offline
        M Offline
        mahd96
        wrote on 9 Jun 2019, 09:46 last edited by
        #3

        @mrjj yes application is 32bit but os is 64bit .
        hard limit?
        i checked it occures when RAM reached to 1.7G

        M 1 Reply Last reply 9 Jun 2019, 09:50
        0
        • M mahd96
          9 Jun 2019, 09:46

          @mrjj yes application is 32bit but os is 64bit .
          hard limit?
          i checked it occures when RAM reached to 1.7G

          M Offline
          M Offline
          mrjj
          Lifetime Qt Champion
          wrote on 9 Jun 2019, 09:50 last edited by mrjj 6 Sept 2019, 09:51
          #4

          @mahd96
          Hi
          On the windows platform, please see here
          https://docs.microsoft.com/en-us/windows/desktop/Memory/4-gigabyte-tuning
          So your app has around 2 GB to use.
          https://docs.microsoft.com/en-us/windows/desktop/Memory/memory-limits-for-windows-releases#physical-memory-limits-windows-10
          So most likely at 1.7 GB, you try to allocate a QImage that want to use way more memory (than 300 MB) and it fails.

          1 Reply Last reply
          4
          • M mahd96
            9 Jun 2019, 09:09

            windows stop allocating memory to my app after 1.7G memory usage. i have allocated some page file. but it seemed to not working because i have some logs that indicates appliucation is out of memory:
            QImage :: out of memory return null
            QPainter :: can not start ...
            QThread :: start() :: can not start
            and after these whenever a signal emits application crashs!
            what can i do before i optimize my memory usage that i decrease this crashes?

            J Offline
            J Offline
            JKSH
            Moderators
            wrote on 9 Jun 2019, 10:59 last edited by JKSH 6 Nov 2019, 05:38
            #5

            @mahd96 said in Out of Memory:

            what can i do before i optimize my memory usage that i decrease this crashes?

            You can create a 64-bit app. That allows your app to use more than 2GB without changing Windows settings.

            Qt Doc Search for browsers: forum.qt.io/topic/35616/web-browser-extension-for-improved-doc-searches

            1 Reply Last reply
            2

            1/5

            9 Jun 2019, 09:09

            • Login

            • Login or register to search.
            1 out of 5
            • First post
              1/5
              Last post
            0
            • Categories
            • Recent
            • Tags
            • Popular
            • Users
            • Groups
            • Search
            • Get Qt Extensions
            • Unsolved