<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[Speicherbedarf]]></title><description><![CDATA[<pre><code class="language-cpp">double* a = new double[10000000];

//tu was damit
</code></pre>
<p>10^7 double Wert entsprechen 8*10^7 Byte was umgerechnet etwa 76 GB entsprechen dürfte. Wieso funktioniert das Programm, das obigen Quellcode enthält dennoch und zeigt eine Speicherauslastung von gerade mal 20%. Werden da Gigabyte-Weise Daten auf die Festplatte geschrieben?</p>
]]></description><link>https://www.c-plusplus.net/forum/topic/301219/speicherbedarf</link><generator>RSS for Node</generator><lastBuildDate>Wed, 12 Aug 2026 03:37:23 GMT</lastBuildDate><atom:link href="https://www.c-plusplus.net/forum/topic/301219.rss" rel="self" type="application/rss+xml"/><pubDate>Thu, 22 Mar 2012 00:31:49 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to Speicherbedarf on Thu, 22 Mar 2012 00:31:49 GMT]]></title><description><![CDATA[<pre><code class="language-cpp">double* a = new double[10000000];

//tu was damit
</code></pre>
<p>10^7 double Wert entsprechen 8*10^7 Byte was umgerechnet etwa 76 GB entsprechen dürfte. Wieso funktioniert das Programm, das obigen Quellcode enthält dennoch und zeigt eine Speicherauslastung von gerade mal 20%. Werden da Gigabyte-Weise Daten auf die Festplatte geschrieben?</p>
]]></description><link>https://www.c-plusplus.net/forum/post/2193948</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/2193948</guid><dc:creator><![CDATA[shisha]]></dc:creator><pubDate>Thu, 22 Mar 2012 00:31:49 GMT</pubDate></item><item><title><![CDATA[Reply to Speicherbedarf on Thu, 22 Mar 2012 00:35:59 GMT]]></title><description><![CDATA[<p>Mal rechnen: 10000000 * 8 / 1024 / 1024<br />
76.2939453 MB, nicht GB. <img
      src="https://www.c-plusplus.net/forum/plugins/nodebb-plugin-emoji/emoji/emoji-one/1f609.png?v=ab1pehoraso"
      class="not-responsive emoji emoji-emoji-one emoji--winking_face"
      title=";)"
      alt="😉"
    /></p>
]]></description><link>https://www.c-plusplus.net/forum/post/2193950</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/2193950</guid><dc:creator><![CDATA[cooky451]]></dc:creator><pubDate>Thu, 22 Mar 2012 00:35:59 GMT</pubDate></item><item><title><![CDATA[Reply to Speicherbedarf on Thu, 22 Mar 2012 00:40:18 GMT]]></title><description><![CDATA[<p>ups, das passiert wenn man die KiloByte ignoriert ^^</p>
]]></description><link>https://www.c-plusplus.net/forum/post/2193954</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/2193954</guid><dc:creator><![CDATA[shisha]]></dc:creator><pubDate>Thu, 22 Mar 2012 00:40:18 GMT</pubDate></item><item><title><![CDATA[Reply to Speicherbedarf on Thu, 22 Mar 2012 11:06:08 GMT]]></title><description><![CDATA[<p>Unter Linux kannst du auch mehr anfordern als da ist. Linux ist so optimistisch, dass es davon ausgeht, dass du nicht alles brauchst. Solltest Du doch genug Bytes davon angefasst haben, dann sterben ein paar Prozesse (Pech gehabt).</p>
]]></description><link>https://www.c-plusplus.net/forum/post/2194080</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/2194080</guid><dc:creator><![CDATA[krümelkacker]]></dc:creator><pubDate>Thu, 22 Mar 2012 11:06:08 GMT</pubDate></item><item><title><![CDATA[Reply to Speicherbedarf on Thu, 22 Mar 2012 13:23:50 GMT]]></title><description><![CDATA[<p>krümelkacker schrieb:</p>
<blockquote>
<p>Linux ist so optimistisch, dass es davon ausgeht, dass du nicht alles brauchst. Solltest Du doch genug Bytes davon angefasst haben, dann sterben ein paar Prozesse (Pech gehabt).</p>
</blockquote>
<p>Naja, das stimmt nicht so ganz. Linux ist allenfalls so optimistisch, weil es weiß, dass es einen Swap gibt. Werden doch mal zu viel Bytes angefasst, wird eben ausgelagert. Prozesse sterben da keine - das gibt es nur unter Android.</p>
]]></description><link>https://www.c-plusplus.net/forum/post/2194136</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/2194136</guid><dc:creator><![CDATA[WaHoooo]]></dc:creator><pubDate>Thu, 22 Mar 2012 13:23:50 GMT</pubDate></item><item><title><![CDATA[Reply to Speicherbedarf on Thu, 22 Mar 2012 13:32:11 GMT]]></title><description><![CDATA[<p>WaHoooo schrieb:</p>
<blockquote>
<p>Naja, das stimmt nicht so ganz. Linux ist allenfalls so optimistisch, weil es weiß, dass es einen Swap gibt. Werden doch mal zu viel Bytes angefasst, wird eben ausgelagert. Prozesse sterben da keine - das gibt es nur unter Android.</p>
</blockquote>
<p>Google mal nach Linux OOM Killer.</p>
<p>HTH (zwei Postings von dir, zweimal Müll, das fängt ja gut an)</p>
]]></description><link>https://www.c-plusplus.net/forum/post/2194140</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/2194140</guid><dc:creator><![CDATA[Bashar]]></dc:creator><pubDate>Thu, 22 Mar 2012 13:32:11 GMT</pubDate></item><item><title><![CDATA[Reply to Speicherbedarf on Thu, 22 Mar 2012 13:39:56 GMT]]></title><description><![CDATA[<p>shisha schrieb:</p>
<blockquote>
<p>10^7 double Wert entsprechen <strong>8</strong>*10^7 Byte</p>
</blockquote>
<p>sizeof(double) == 8? Welche Plattform?</p>
]]></description><link>https://www.c-plusplus.net/forum/post/2194151</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/2194151</guid><dc:creator><![CDATA[pumuckl]]></dc:creator><pubDate>Thu, 22 Mar 2012 13:39:56 GMT</pubDate></item><item><title><![CDATA[Reply to Speicherbedarf on Thu, 22 Mar 2012 13:41:58 GMT]]></title><description><![CDATA[<p>pumuckl schrieb:</p>
<blockquote>
<p>shisha schrieb:</p>
<blockquote>
<p>10^7 double Wert entsprechen <strong>8</strong>*10^7 Byte</p>
</blockquote>
<p>sizeof(double) == 8? Welche Plattform?</p>
</blockquote>
<p>So ziemlich jede die ich kenne?</p>
]]></description><link>https://www.c-plusplus.net/forum/post/2194152</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/2194152</guid><dc:creator><![CDATA[dot]]></dc:creator><pubDate>Thu, 22 Mar 2012 13:41:58 GMT</pubDate></item><item><title><![CDATA[Reply to Speicherbedarf on Thu, 22 Mar 2012 13:44:55 GMT]]></title><description><![CDATA[<p>dot schrieb:</p>
<blockquote>
<p>pumuckl schrieb:</p>
<blockquote>
<p>shisha schrieb:</p>
<blockquote>
<p>10^7 double Wert entsprechen <strong>8</strong>*10^7 Byte</p>
</blockquote>
<p>sizeof(double) == 8? Welche Plattform?</p>
</blockquote>
<p>So ziemlich jede die ich kenne?</p>
</blockquote>
<p>Huh. Wie komm ich drauf dass das irgendwo 12 gewesen sei?? <img
      src="https://www.c-plusplus.net/forum/plugins/nodebb-plugin-emoji/emoji/emoji-one/1f615.png?v=ab1pehoraso"
      class="not-responsive emoji emoji-emoji-one emoji--confused_face"
      title=":confused:"
      alt="😕"
    /></p>
]]></description><link>https://www.c-plusplus.net/forum/post/2194153</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/2194153</guid><dc:creator><![CDATA[pumuckl]]></dc:creator><pubDate>Thu, 22 Mar 2012 13:44:55 GMT</pubDate></item><item><title><![CDATA[Reply to Speicherbedarf on Thu, 22 Mar 2012 13:49:04 GMT]]></title><description><![CDATA[<p>pumuckl schrieb:</p>
<blockquote>
<p>dot schrieb:</p>
<blockquote>
<p>pumuckl schrieb:</p>
<blockquote>
<p>shisha schrieb:</p>
<blockquote>
<p>10^7 double Wert entsprechen <strong>8</strong>*10^7 Byte</p>
</blockquote>
<p>sizeof(double) == 8? Welche Plattform?</p>
</blockquote>
<p>So ziemlich jede die ich kenne?</p>
</blockquote>
<p>Huh. Wie komm ich drauf dass das irgendwo 12 gewesen sei?? <img
      src="https://www.c-plusplus.net/forum/plugins/nodebb-plugin-emoji/emoji/emoji-one/1f615.png?v=ab1pehoraso"
      class="not-responsive emoji emoji-emoji-one emoji--confused_face"
      title=":confused:"
      alt="😕"
    /></p>
</blockquote>
<p>Vielleicht hast du's mit long double verwechselt, das is unter manchen Compilern/Plattformen so zwischen 10 und 16 Byte groß (z.B. für die 80bit FPU Register von x86)...</p>
]]></description><link>https://www.c-plusplus.net/forum/post/2194154</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/2194154</guid><dc:creator><![CDATA[dot]]></dc:creator><pubDate>Thu, 22 Mar 2012 13:49:04 GMT</pubDate></item><item><title><![CDATA[Reply to Speicherbedarf on Thu, 22 Mar 2012 14:37:49 GMT]]></title><description><![CDATA[<p>Bashar schrieb:</p>
<blockquote>
<p>Google mal nach Linux OOM Killer.</p>
<p>HTH (zwei Postings von dir, zweimal Müll, das fängt ja gut an)</p>
</blockquote>
<p>Ja. Genau. Wenn der Speicher knapp wird, schießt Linux sinn- und planlos irgend welche Prozesse ab (init vielleicht weil es schon so sehr lange läuft? Oder httpd bzw. mysqld weil die gerade so schön viel RAM verbrauchen?).</p>
<p>Bevor du solchen unreflektierten Müll postest, solltest du die Artikel mal lesen, auf die du hier so gönnerhaft verweist.</p>
]]></description><link>https://www.c-plusplus.net/forum/post/2194200</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/2194200</guid><dc:creator><![CDATA[WaHoooo]]></dc:creator><pubDate>Thu, 22 Mar 2012 14:37:49 GMT</pubDate></item><item><title><![CDATA[Reply to Speicherbedarf on Thu, 22 Mar 2012 14:43:05 GMT]]></title><description><![CDATA[<p>edit: Ironiedetektor war kaputt.</p>
]]></description><link>https://www.c-plusplus.net/forum/post/2194207</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/2194207</guid><dc:creator><![CDATA[SeppJ]]></dc:creator><pubDate>Thu, 22 Mar 2012 14:43:05 GMT</pubDate></item><item><title><![CDATA[Reply to Speicherbedarf on Thu, 22 Mar 2012 16:41:39 GMT]]></title><description><![CDATA[<p>WaHoooo schrieb:</p>
<blockquote>
<p>Bashar schrieb:</p>
<blockquote>
<p>Google mal nach Linux OOM Killer.</p>
<p>HTH (zwei Postings von dir, zweimal Müll, das fängt ja gut an)</p>
</blockquote>
<p>Ja. Genau. Wenn der Speicher knapp wird, schießt Linux sinn- und planlos irgend welche Prozesse ab</p>
</blockquote>
<p>&quot;sinn- und planlos&quot; hat wer behauptet?</p>
<blockquote>
<p>Bevor du solchen unreflektierten Müll postest, solltest du die Artikel mal lesen, auf die du hier so gönnerhaft verweist.</p>
</blockquote>
<p>Jaja, ich bin schuld, dass du Müll schreibst. Bekanntes Gefühl <img
      src="https://www.c-plusplus.net/forum/plugins/nodebb-plugin-emoji/emoji/emoji-one/1f642.png?v=ab1pehoraso"
      class="not-responsive emoji emoji-emoji-one emoji--slightly_smiling_face"
      title=":)"
      alt="🙂"
    /></p>
]]></description><link>https://www.c-plusplus.net/forum/post/2194286</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/2194286</guid><dc:creator><![CDATA[Bashar]]></dc:creator><pubDate>Thu, 22 Mar 2012 16:41:39 GMT</pubDate></item></channel></rss>