summaryrefslogtreecommitdiff
path: root/src/lib/evas/cserve2/evas_cs2.h
diff options
context:
space:
mode:
authorJean-Philippe Andre <jp.andre@samsung.com>2013-08-21 13:51:15 +0900
committerJean-Philippe Andre <jp.andre@samsung.com>2013-10-28 15:47:14 +0900
commit4f5c48236f4152964868914ad106c1cb928bc41e (patch)
treea95cf48287b37f6f8b387b31b8664eeba692f95a /src/lib/evas/cserve2/evas_cs2.h
parent1e4ee656a0c44cbf915e124aa59c50fdde9f0973 (diff)
evas/cserve2: Add proper tags to shm arrays
Use tags such as INDX, FONT, IMAG, FILE. These can help debugging and for robustness, as they will be visible in the memory dump. Update generation_id after repack as well
Diffstat (limited to 'src/lib/evas/cserve2/evas_cs2.h')
-rw-r--r--src/lib/evas/cserve2/evas_cs2.h9
1 files changed, 8 insertions, 1 deletions
diff --git a/src/lib/evas/cserve2/evas_cs2.h b/src/lib/evas/cserve2/evas_cs2.h
index 32e70a7863..2d3ad05b12 100644
--- a/src/lib/evas/cserve2/evas_cs2.h
+++ b/src/lib/evas/cserve2/evas_cs2.h
@@ -297,9 +297,9 @@ typedef int string_t;
297 297
298struct _Shared_Array_Header { 298struct _Shared_Array_Header {
299 int32_t tag; 299 int32_t tag;
300 int32_t generation_id;
300 int32_t elemsize; 301 int32_t elemsize;
301 int32_t count; 302 int32_t count;
302 int32_t generation_id;
303 int32_t emptyidx; 303 int32_t emptyidx;
304 int32_t sortedidx; 304 int32_t sortedidx;
305 int32_t _reserved1; 305 int32_t _reserved1;
@@ -310,6 +310,8 @@ struct _Shm_Object {
310 SHMOBJECT; 310 SHMOBJECT;
311}; 311};
312 312
313#define STRING_INDEX_ARRAY_TAG ('S' | 'T' << 8 | 'R' << 16 | 'N' << 24)
314#define STRING_MEMPOOL_FAKETAG ('S' | 'T' << 8 | 'R' << 16 | 'M' << 24)
313struct _Index_Entry { 315struct _Index_Entry {
314 SHMOBJECT; 316 SHMOBJECT;
315 // Block entry 317 // Block entry
@@ -318,6 +320,7 @@ struct _Index_Entry {
318 int32_t shmid; 320 int32_t shmid;
319}; 321};
320 322
323#define FILE_DATA_ARRAY_TAG ('F' | 'I' << 8 | 'L' << 16 | 'E' << 24)
321struct _File_Data { 324struct _File_Data {
322 SHMOBJECT; 325 SHMOBJECT;
323 string_t path; 326 string_t path;
@@ -331,6 +334,7 @@ struct _File_Data {
331 Eina_Bool invalid : 1; 334 Eina_Bool invalid : 1;
332}; 335};
333 336
337#define IMAGE_DATA_ARRAY_TAG ('I' | 'M' << 8 | 'A' << 16 | 'G' << 24)
334struct _Image_Data { 338struct _Image_Data {
335 SHMOBJECT; 339 SHMOBJECT;
336 uint32_t file_id; 340 uint32_t file_id;
@@ -341,6 +345,7 @@ struct _Image_Data {
341 Eina_Bool doload : 1; 345 Eina_Bool doload : 1;
342}; 346};
343 347
348#define FONT_DATA_ARRAY_TAG ('F' | 'O' << 8 | 'N' << 16 | 'T' << 24)
344struct _Font_Data { 349struct _Font_Data {
345 SHMOBJECT; 350 SHMOBJECT;
346 string_t name; 351 string_t name;
@@ -351,6 +356,8 @@ struct _Font_Data {
351 uint32_t dpi; 356 uint32_t dpi;
352}; 357};
353 358
359#define GLYPH_INDEX_ARRAY_TAG ('G' | 'L' << 8 | 'I' << 16 | 'D' << 24)
360#define GLYPH_DATA_ARRAY_TAG ('G' | 'L' << 8 | 'P' << 16 | 'H' << 24)
354struct _Glyph_Data { 361struct _Glyph_Data {
355 SHMOBJECT; 362 SHMOBJECT;
356 uint32_t index; 363 uint32_t index;