<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: MQX 4.2 Task Stack Allocation &amp; Compiler Optimization in MQX Software Solutions</title>
    <link>https://community.nxp.com/t5/MQX-Software-Solutions/MQX-4-2-Task-Stack-Allocation-Compiler-Optimization/m-p/642218#M17096</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Daniel,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks for your response!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;That information was helpful!&lt;/P&gt;&lt;P&gt;Would you happen to know of any documentation that I could read to learn more?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks for your time,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Jason&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 15 Mar 2017 19:19:59 GMT</pubDate>
    <dc:creator>jasonscott</dc:creator>
    <dc:date>2017-03-15T19:19:59Z</dc:date>
    <item>
      <title>MQX 4.2 Task Stack Allocation &amp; Compiler Optimization</title>
      <link>https://community.nxp.com/t5/MQX-Software-Solutions/MQX-4-2-Task-Stack-Allocation-Compiler-Optimization/m-p/642216#M17094</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Good Afternoon,&lt;/P&gt;&lt;P&gt;I am having serious memory issues and i need help understanding a few things.&lt;/P&gt;&lt;P&gt;For starters here is some background information about what i am trying to do:&lt;/P&gt;&lt;P&gt;I am working on a custom board using the k60 processor.&lt;/P&gt;&lt;P&gt;I am using the KDS 3 with the GCC compiler.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;What I need help with:&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;1) How do MQX tasks/sub-tasks&amp;nbsp;allocate stack size &amp;amp; location?&lt;/STRONG&gt;I currently run multiple sub tasks out of my "main task". I setup my SD card, start the shell, and a few other things.&amp;nbsp;After entering a third task i feel like i am running out or stack space to allocate.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="pastedImage_4.png"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/15627i0E66EAC555822D47/image-size/large?v=v2&amp;amp;px=999" role="button" title="pastedImage_4.png" alt="pastedImage_4.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;The screenshot above is right before i start my next task. After i enter the task, the MQX stack usage window goes gray and i can not see any information. however, i checked the stack pointer and i am at 0x1fffe938. I think i am expanding into another region or something.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;2) Can I set a stack space for each individual task in external ram? If so, could i please see an example?&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;3) I read that the boot_stack is only used for the interrupts&amp;nbsp;and a few basic things, are all of my MQX tasks running out of the boot_stack? Probably not right?&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;4) Does anyone have any recommendations on if building the bsp library's&amp;nbsp;using optimizations/ debugging would alter my memory vs a release version? Again I am using the GCC 4.8.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&amp;nbsp;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;Thanks for your time,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any information or things to try would be appreciated!&amp;nbsp;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 10 Mar 2017 19:15:40 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MQX-Software-Solutions/MQX-4-2-Task-Stack-Allocation-Compiler-Optimization/m-p/642216#M17094</guid>
      <dc:creator>jasonscott</dc:creator>
      <dc:date>2017-03-10T19:15:40Z</dc:date>
    </item>
    <item>
      <title>Re: MQX 4.2 Task Stack Allocation &amp; Compiler Optimization</title>
      <link>https://community.nxp.com/t5/MQX-Software-Solutions/MQX-4-2-Task-Stack-Allocation-Compiler-Optimization/m-p/642217#M17095</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Jason:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;1) Memory for task's stack is allocated dynamically when the task is created from the default memory pool. This default memory pool is used also for memory allocation from other kernel components, like semaphores and so on.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;2) Yes, you can. To start a task with its stack in a given memory, use _task_create_at() function; there you can give the stack_ptr and stack_size to point to a DDR2 location /SRAM location&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Daniel&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 14 Mar 2017 14:48:19 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MQX-Software-Solutions/MQX-4-2-Task-Stack-Allocation-Compiler-Optimization/m-p/642217#M17095</guid>
      <dc:creator>danielchen</dc:creator>
      <dc:date>2017-03-14T14:48:19Z</dc:date>
    </item>
    <item>
      <title>Re: MQX 4.2 Task Stack Allocation &amp; Compiler Optimization</title>
      <link>https://community.nxp.com/t5/MQX-Software-Solutions/MQX-4-2-Task-Stack-Allocation-Compiler-Optimization/m-p/642218#M17096</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Daniel,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks for your response!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;That information was helpful!&lt;/P&gt;&lt;P&gt;Would you happen to know of any documentation that I could read to learn more?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks for your time,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Jason&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Mar 2017 19:19:59 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MQX-Software-Solutions/MQX-4-2-Task-Stack-Allocation-Compiler-Optimization/m-p/642218#M17096</guid>
      <dc:creator>jasonscott</dc:creator>
      <dc:date>2017-03-15T19:19:59Z</dc:date>
    </item>
    <item>
      <title>Re: MQX 4.2 Task Stack Allocation &amp; Compiler Optimization</title>
      <link>https://community.nxp.com/t5/MQX-Software-Solutions/MQX-4-2-Task-Stack-Allocation-Compiler-Optimization/m-p/642219#M17097</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Jason:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The MQX documents are under the MQX installation folder,&lt;/P&gt;&lt;P&gt;Freescale_MQX_4_2\doc\&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="pastedImage_1.png"&gt;&lt;img src="https://community.nxp.com/t5/image/serverpage/image-id/18446i2D7F5D43083A1681/image-size/large?v=v2&amp;amp;px=999" role="button" title="pastedImage_1.png" alt="pastedImage_1.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The deference between &lt;STRONG&gt;Release&lt;/STRONG&gt; mode and &lt;STRONG&gt;Debug&lt;/STRONG&gt; mode, is in &lt;STRONG&gt;Debug&lt;/STRONG&gt; mode there will be &lt;STRONG&gt;debug&lt;/STRONG&gt; information added into the executable.&amp;nbsp; And the optimization level is different.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Daniel&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 16 Mar 2017 14:23:21 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MQX-Software-Solutions/MQX-4-2-Task-Stack-Allocation-Compiler-Optimization/m-p/642219#M17097</guid>
      <dc:creator>danielchen</dc:creator>
      <dc:date>2017-03-16T14:23:21Z</dc:date>
    </item>
    <item>
      <title>Re: MQX 4.2 Task Stack Allocation &amp; Compiler Optimization</title>
      <link>https://community.nxp.com/t5/MQX-Software-Solutions/MQX-4-2-Task-Stack-Allocation-Compiler-Optimization/m-p/642220#M17098</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Daniel,&lt;/P&gt;&lt;P&gt;Sorry its taken me a bit to respond.&lt;/P&gt;&lt;P&gt;Thank you for the information and clarification.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;-Jason&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 23 Mar 2017 19:06:51 GMT</pubDate>
      <guid>https://community.nxp.com/t5/MQX-Software-Solutions/MQX-4-2-Task-Stack-Allocation-Compiler-Optimization/m-p/642220#M17098</guid>
      <dc:creator>jasonscott</dc:creator>
      <dc:date>2017-03-23T19:06:51Z</dc:date>
    </item>
  </channel>
</rss>

