Re: [Intel-gfx] [PATCH] intel-gpu-tools: Change type of variable from unsigned to uint64_t in gem_stress

2014-08-05 Thread Popov, Pavel E
Hi Daniel,

 We have tons of places which use gem_aperture_size. Have you reviewed them 
 all?
I've already looked at these places in latest trunk. I observed that type 
overflow also can happen in tests gem_evict_alignment and gem_evict_everything. 
But for our needs we only ported intel-gpu-tools 1.3 which doesn't contain 
these tests and I cannot check them on our configuration. At the moment we use 
4GB for aperture size for our driver and observed that only gem_stress doesn't 
work correctly. We caught the bug after this test was fixed. Thanks for this 
test!

 There's a procedure to remove it (it's a exchange setting for all countries), 
 the OTC wiki has a howto (no link atm).
I found the link https://opensource.intel.com/linux-wiki/EmailDisclaimer. 
Thanks for the tip. I'll do it.

Regards,
Pavel


-Original Message-
From: Daniel Vetter [mailto:daniel.vet...@ffwll.ch] On Behalf Of Daniel Vetter
Sent: Monday, August 04, 2014 4:10 PM
To: Popov, Pavel E
Cc: intel-gfx@lists.freedesktop.org
Subject: Re: [Intel-gfx] [PATCH] intel-gpu-tools: Change type of variable from 
unsigned to uint64_t in gem_stress

On Fri, Aug 01, 2014 at 12:10:44PM +0700, Pavel Popov wrote:
 To run gem_stress with the correct number of buffers even if aperture size = 
 4GB.
 
 Signed-off-by: Pavel Popov pavel.e.po...@intel.com
 ---
  tests/gem_stress.c | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
 
 diff --git a/tests/gem_stress.c b/tests/gem_stress.c index 
 3bbe487..313a82a 100644
 --- a/tests/gem_stress.c
 +++ b/tests/gem_stress.c
 @@ -737,7 +737,7 @@ static int parse_options(int opt, int opt_index)  
 static void init(void)  {
   int i;
 - unsigned tmp;
 + uint64_t tmp;

We have tons of places which use gem_aperture_size. Have you reviewed them
all?
-Daniel

  
   if (options.num_buffers == 0) {
   tmp = gem_aperture_size(drm_fd);
 -- 
 1.9.1
 
 
 
 Closed Joint Stock Company Intel A/O
 Registered legal address: Krylatsky Hills Business Park, 
 17 Krylatskaya Str., Bldg 4, Moscow 121614, 
 Russian Federation
 
 This e-mail and any attachments may contain confidential material for
 the sole use of the intended recipient(s). Any review or distribution
 by others is strictly prohibited. If you are not the intended
 recipient, please contact the sender and delete all copies.
 
 ___
 Intel-gfx mailing list
 Intel-gfx@lists.freedesktop.org
 http://lists.freedesktop.org/mailman/listinfo/intel-gfx

-- 
Daniel Vetter
Software Engineer, Intel Corporation
+41 (0) 79 365 57 48 - http://blog.ffwll.ch


Closed Joint Stock Company Intel A/O
Registered legal address: Krylatsky Hills Business Park, 
17 Krylatskaya Str., Bldg 4, Moscow 121614, 
Russian Federation

This e-mail and any attachments may contain confidential material for
the sole use of the intended recipient(s). Any review or distribution
by others is strictly prohibited. If you are not the intended
recipient, please contact the sender and delete all copies.

___
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx


Re: [Intel-gfx] [PATCH] intel-gpu-tools: Change type of variable from unsigned to uint64_t in gem_stress

2014-08-05 Thread Daniel Vetter
On Tue, Aug 5, 2014 at 1:38 PM, Popov, Pavel E pavel.e.po...@intel.com wrote:
 We have tons of places which use gem_aperture_size. Have you reviewed them 
 all?
 I've already looked at these places in latest trunk. I observed that type 
 overflow also can happen in tests gem_evict_alignment and 
 gem_evict_everything. But for our needs we only ported intel-gpu-tools 1.3 
 which doesn't contain these tests and I cannot check them on our 
 configuration. At the moment we use 4GB for aperture size for our driver and 
 observed that only gem_stress doesn't work correctly. We caught the bug after 
 this test was fixed. Thanks for this test!

Uhg, i-g-t 1.3 is rather old ... Can you try to roll forward your copy
of i-g-t (_highly_ recommneded to stay at current code for validation,
or at least always the latest release) and look at the other places?
Unfortunately I don't know of any gcc tricks to make sure there's no
integer precision truncation, so we have to rely on testing and review
:(
-Daniel
-- 
Daniel Vetter
Software Engineer, Intel Corporation
+41 (0) 79 365 57 48 - http://blog.ffwll.ch
___
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx


Re: [Intel-gfx] [PATCH] intel-gpu-tools: Change type of variable from unsigned to uint64_t in gem_stress

2014-08-04 Thread Daniel Vetter
On Fri, Aug 01, 2014 at 12:10:44PM +0700, Pavel Popov wrote:
 To run gem_stress with the correct number of buffers even if aperture size = 
 4GB.
 
 Signed-off-by: Pavel Popov pavel.e.po...@intel.com
 ---
  tests/gem_stress.c | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
 
 diff --git a/tests/gem_stress.c b/tests/gem_stress.c
 index 3bbe487..313a82a 100644
 --- a/tests/gem_stress.c
 +++ b/tests/gem_stress.c
 @@ -737,7 +737,7 @@ static int parse_options(int opt, int opt_index)
  static void init(void)
  {
   int i;
 - unsigned tmp;
 + uint64_t tmp;

We have tons of places which use gem_aperture_size. Have you reviewed them
all?
-Daniel

  
   if (options.num_buffers == 0) {
   tmp = gem_aperture_size(drm_fd);
 -- 
 1.9.1
 
 
 
 Closed Joint Stock Company Intel A/O
 Registered legal address: Krylatsky Hills Business Park, 
 17 Krylatskaya Str., Bldg 4, Moscow 121614, 
 Russian Federation
 
 This e-mail and any attachments may contain confidential material for
 the sole use of the intended recipient(s). Any review or distribution
 by others is strictly prohibited. If you are not the intended
 recipient, please contact the sender and delete all copies.
 
 ___
 Intel-gfx mailing list
 Intel-gfx@lists.freedesktop.org
 http://lists.freedesktop.org/mailman/listinfo/intel-gfx

-- 
Daniel Vetter
Software Engineer, Intel Corporation
+41 (0) 79 365 57 48 - http://blog.ffwll.ch
___
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx


[Intel-gfx] [PATCH] intel-gpu-tools: Change type of variable from unsigned to uint64_t in gem_stress

2014-07-31 Thread Pavel Popov
To run gem_stress with the correct number of buffers even if aperture size = 
4GB.

Signed-off-by: Pavel Popov pavel.e.po...@intel.com
---
 tests/gem_stress.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/tests/gem_stress.c b/tests/gem_stress.c
index 3bbe487..313a82a 100644
--- a/tests/gem_stress.c
+++ b/tests/gem_stress.c
@@ -737,7 +737,7 @@ static int parse_options(int opt, int opt_index)
 static void init(void)
 {
int i;
-   unsigned tmp;
+   uint64_t tmp;
 
if (options.num_buffers == 0) {
tmp = gem_aperture_size(drm_fd);
-- 
1.9.1



Closed Joint Stock Company Intel A/O
Registered legal address: Krylatsky Hills Business Park, 
17 Krylatskaya Str., Bldg 4, Moscow 121614, 
Russian Federation

This e-mail and any attachments may contain confidential material for
the sole use of the intended recipient(s). Any review or distribution
by others is strictly prohibited. If you are not the intended
recipient, please contact the sender and delete all copies.

___
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx