我們的品牌

Impact-Company-Logo-English Black-01-177x54

歡迎造訪施耐德電機全球網站

歡迎訪問我們的網站
		
我们今天能为您提供什么帮助?
Adding a variable of type REAL does not change the value shown in the Memory Consumption window.
Issue
Memory consumption window appears to be inaccurate.

Product Line
Unity Pro, Control Expert 14

Environment
Windows 10, Windows 7

Resolution
The memory consumption window appears to be inaccurate.  If a new variable is added (i.e.,
REAL, etc.),
the value shown in the Memory Consumption window does not change.



Memory Usage

This feature works as designed.  The displayed value is correct.  The reason for issue is due to the following he behavior:
  • Variables are allocated in memory block.
  • The size of a memory block is always a multiple of 16 bytes.
  • Variable alignment constraint may generate small gaps in memory.

For instance, if you, declare a variable of type BYTE (1 byte of memory is required). It could result in the
memory consumption screen increasing by 16 bytes with only 1 byte used.  However,
if you declare another variable with
same type (or another type), the value shown  in the screen will not change because
the remaining 15 bytes left is reserved for later
use on the next declared variables.


Variable constraint infers that the variable must be allocated in memory to an offset which is a multiple of its size.
The maximum variable alignment constraint is 4.   This means that if you declare a variable using a type with a large byte
size (i.e.,  DDT or ARRAY).  Unity does not use the type size for alignment constraint.  Instead, it uses the value of 4.

A two (2 ) bytes size variable must be allocated to an offset multiple of 2.  As a result, there could be a small gap
in memory.


i.e.,

If the 3 bytes of the 16 bytes were already allocated when a new two byte variable is added, the new variable would be assigned to the bytes 5 and 6.

施耐德電機Taiwan

探索更多
系列:
探索更多
系列:

需要協助?

  • 產品選型工具

    快速輕鬆地為您的應用找到合適的產品和附件。

  • 取得報價

    立即線上提交您的銷售需求,專業團隊將主動聯繫您。

  • 購買地點

    輕鬆在您所在地區找到最近的施耐德電機經銷商。

  • 支援中心

    在同一位置找到滿足您所有需求的支援資源。

  • 產品文檔
  • 軟體下載
  • 產品選型工具
  • 產品替代和替換
  • 幫助和聯絡中心
  • 尋找我們的辦公室
  • 取得報價
  • 人才招募
  • 公司簡介
  • 舉報不當行為
  • 無障礙
  • 新聞中心
  • 投資者
  • 專業洞察
  • 台灣施耐德電機學院
  • 綠色影響力落差調查
  • Schneider Go Green 2025
  • 隱私政策
  • Cookie通告
  • 使用條款
  • Change your cookie settings