<?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 Pointer or array? in 8-bit Microcontrollers</title>
    <link>https://community.nxp.com/t5/8-bit-Microcontrollers/Pointer-or-array/m-p/191960#M14773</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;In an 8-bit mcu, is better in function arguments use pointer or value?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 14 Apr 2010 19:48:58 GMT</pubDate>
    <dc:creator>roberto_m</dc:creator>
    <dc:date>2010-04-14T19:48:58Z</dc:date>
    <item>
      <title>Pointer or array?</title>
      <link>https://community.nxp.com/t5/8-bit-Microcontrollers/Pointer-or-array/m-p/191960#M14773</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;In an 8-bit mcu, is better in function arguments use pointer or value?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 14 Apr 2010 19:48:58 GMT</pubDate>
      <guid>https://community.nxp.com/t5/8-bit-Microcontrollers/Pointer-or-array/m-p/191960#M14773</guid>
      <dc:creator>roberto_m</dc:creator>
      <dc:date>2010-04-14T19:48:58Z</dc:date>
    </item>
    <item>
      <title>Re: Pointer or array?</title>
      <link>https://community.nxp.com/t5/8-bit-Microcontrollers/Pointer-or-array/m-p/191961#M14774</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Pointer of course. Passing array by value you rise stack space requirements.&amp;nbsp;Also passing array by value slows down execution, because it takes time to copy array from source to the stack.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 14 Apr 2010 20:36:26 GMT</pubDate>
      <guid>https://community.nxp.com/t5/8-bit-Microcontrollers/Pointer-or-array/m-p/191961#M14774</guid>
      <dc:creator>kef</dc:creator>
      <dc:date>2010-04-14T20:36:26Z</dc:date>
    </item>
    <item>
      <title>Re: Pointer or array?</title>
      <link>https://community.nxp.com/t5/8-bit-Microcontrollers/Pointer-or-array/m-p/191962#M14775</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello Roberto,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;My understanding is that, when a function uses an array name as an argument, the contents of the array are &lt;U&gt;not&lt;/U&gt; passed to the function, but&amp;nbsp;a pointer to the first element of the array is automatically passed instead.&amp;nbsp; Therefore I would suspect that passing an array name, or explicitly passing a pointer should give similar results.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Mac&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 14 Apr 2010 23:39:35 GMT</pubDate>
      <guid>https://community.nxp.com/t5/8-bit-Microcontrollers/Pointer-or-array/m-p/191962#M14775</guid>
      <dc:creator>bigmac</dc:creator>
      <dc:date>2010-04-14T23:39:35Z</dc:date>
    </item>
    <item>
      <title>Re: Pointer or array?</title>
      <link>https://community.nxp.com/t5/8-bit-Microcontrollers/Pointer-or-array/m-p/191963#M14776</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Correct. There is no way to pass an array by value as a function parameter in the C language.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;void func (int* x); /* this is a pointer */&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;void func(int x[]); /* this is a pointer */&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;void func(int x[10]); /* this is a pointer */&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;In all 3 cases above, a pointer is passed on the stack, and nothing else.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 15 Apr 2010 21:21:42 GMT</pubDate>
      <guid>https://community.nxp.com/t5/8-bit-Microcontrollers/Pointer-or-array/m-p/191963#M14776</guid>
      <dc:creator>Lundin</dc:creator>
      <dc:date>2010-04-15T21:21:42Z</dc:date>
    </item>
  </channel>
</rss>

