Re: RFR: 8172842 Invoke lldb with --batch from failure handler

2017-01-16 Thread Staffan Larsen
Thanks Erik!

> On 16 Jan 2017, at 11:48, Erik Joelsson  wrote:
> 
> Looks good to me.
> 
> /Erik
> 
> 
> On 2017-01-16 09:24, Staffan Larsen wrote:
>> When the failure handler invokes lldb to create a core it looks something 
>> like this:
>> 
>> lldb -o 'attach %p' -o 'process save-core core.%p' -o 'detach' -o 'quit'
>> 
>> However if the attach command fails, the rest of the commands - including 
>> 'quit' - are not being run. This means the lldb process is hung.
>> 
>> Adding '--batch' to the command line overcomes this problem.
>> 
>> Thanks,
>> /Staffan
>> 
>> 
>> diff --git a/test/failure_handler/src/share/conf/mac.properties 
>> b/test/failure_handler/src/share/conf/mac.properties
>> --- a/test/failure_handler/src/share/conf/mac.properties
>> +++ b/test/failure_handler/src/share/conf/mac.properties
>> @@ -64,7 +64,7 @@
>>  native.core.app=bash
>>  native.core.delimiter=\0
>>  native.core.args=-c\0gcore -o ./core.%p %p || \
>> -  (DevToolsSecurity --status | grep -q enabled && lldb -o 'attach %p' -o 
>> 'process save-core core.%p' -o 'detach' -o 'quit')
>> +  (DevToolsSecurity --status | grep -q enabled && lldb --batch -o 'attach 
>> %p' -o 'process save-core core.%p' -o 'detach' -o 'quit')
>>  native.core.params.timeout=360
>>  
>> 
>>  # environment info to gather
>> 
> 



Re: RFR: 8172842 Invoke lldb with --batch from failure handler

2017-01-16 Thread Erik Joelsson

Looks good to me.

/Erik


On 2017-01-16 09:24, Staffan Larsen wrote:

When the failure handler invokes lldb to create a core it looks something like 
this:

lldb -o 'attach %p' -o 'process save-core core.%p' -o 'detach' -o 'quit'

However if the attach command fails, the rest of the commands - including 
'quit' - are not being run. This means the lldb process is hung.

Adding '--batch' to the command line overcomes this problem.

Thanks,
/Staffan


diff --git a/test/failure_handler/src/share/conf/mac.properties 
b/test/failure_handler/src/share/conf/mac.properties
--- a/test/failure_handler/src/share/conf/mac.properties
+++ b/test/failure_handler/src/share/conf/mac.properties
@@ -64,7 +64,7 @@
  native.core.app=bash
  native.core.delimiter=\0
  native.core.args=-c\0gcore -o ./core.%p %p || \
-  (DevToolsSecurity --status | grep -q enabled && lldb -o 'attach %p' -o 
'process save-core core.%p' -o 'detach' -o 'quit')
+  (DevToolsSecurity --status | grep -q enabled && lldb --batch -o 'attach %p' 
-o 'process save-core core.%p' -o 'detach' -o 'quit')
  native.core.params.timeout=360
  

  # environment info to gather





Re: RFR: 8172842 Invoke lldb with --batch from failure handler

2017-01-16 Thread Staffan Larsen
Thanks Dmitry!

> On 16 Jan 2017, at 09:43, Dmitry Samersoff  
> wrote:
> 
> Staffan,
> 
> Looks OK to me.
> 
> -Dmitry
> 
> 
> On 2017-01-16 11:24, Staffan Larsen wrote:
>> When the failure handler invokes lldb to create a core it looks something 
>> like this: 
>> 
>> lldb -o 'attach %p' -o 'process save-core core.%p' -o 'detach' -o 'quit' 
>> 
>> However if the attach command fails, the rest of the commands - including 
>> 'quit' - are not being run. This means the lldb process is hung. 
>> 
>> Adding '--batch' to the command line overcomes this problem. 
>> 
>> Thanks,
>> /Staffan
>> 
>> 
>> diff --git a/test/failure_handler/src/share/conf/mac.properties 
>> b/test/failure_handler/src/share/conf/mac.properties
>> --- a/test/failure_handler/src/share/conf/mac.properties
>> +++ b/test/failure_handler/src/share/conf/mac.properties
>> @@ -64,7 +64,7 @@
>> native.core.app=bash
>> native.core.delimiter=\0
>> native.core.args=-c\0gcore -o ./core.%p %p || \
>> -  (DevToolsSecurity --status | grep -q enabled && lldb -o 'attach %p' -o 
>> 'process save-core core.%p' -o 'detach' -o 'quit')
>> +  (DevToolsSecurity --status | grep -q enabled && lldb --batch -o 'attach 
>> %p' -o 'process save-core core.%p' -o 'detach' -o 'quit')
>> native.core.params.timeout=360
>> 
>> # environment info to gather
>> 
> 
> 
> -- 
> Dmitry Samersoff
> Oracle Java development team, Saint Petersburg, Russia
> * I would love to change the world, but they won't give me the sources.



Re: RFR: 8172842 Invoke lldb with --batch from failure handler

2017-01-16 Thread Dmitry Samersoff
Staffan,

Looks OK to me.

-Dmitry


On 2017-01-16 11:24, Staffan Larsen wrote:
> When the failure handler invokes lldb to create a core it looks something 
> like this: 
> 
> lldb -o 'attach %p' -o 'process save-core core.%p' -o 'detach' -o 'quit' 
> 
> However if the attach command fails, the rest of the commands - including 
> 'quit' - are not being run. This means the lldb process is hung. 
> 
> Adding '--batch' to the command line overcomes this problem. 
> 
> Thanks,
> /Staffan
> 
> 
> diff --git a/test/failure_handler/src/share/conf/mac.properties 
> b/test/failure_handler/src/share/conf/mac.properties
> --- a/test/failure_handler/src/share/conf/mac.properties
> +++ b/test/failure_handler/src/share/conf/mac.properties
> @@ -64,7 +64,7 @@
>  native.core.app=bash
>  native.core.delimiter=\0
>  native.core.args=-c\0gcore -o ./core.%p %p || \
> -  (DevToolsSecurity --status | grep -q enabled && lldb -o 'attach %p' -o 
> 'process save-core core.%p' -o 'detach' -o 'quit')
> +  (DevToolsSecurity --status | grep -q enabled && lldb --batch -o 'attach 
> %p' -o 'process save-core core.%p' -o 'detach' -o 'quit')
>  native.core.params.timeout=360
>  
> 
>  # environment info to gather
> 


-- 
Dmitry Samersoff
Oracle Java development team, Saint Petersburg, Russia
* I would love to change the world, but they won't give me the sources.


RFR: 8172842 Invoke lldb with --batch from failure handler

2017-01-16 Thread Staffan Larsen
When the failure handler invokes lldb to create a core it looks something like 
this: 

lldb -o 'attach %p' -o 'process save-core core.%p' -o 'detach' -o 'quit' 

However if the attach command fails, the rest of the commands - including 
'quit' - are not being run. This means the lldb process is hung. 

Adding '--batch' to the command line overcomes this problem. 

Thanks,
/Staffan


diff --git a/test/failure_handler/src/share/conf/mac.properties 
b/test/failure_handler/src/share/conf/mac.properties
--- a/test/failure_handler/src/share/conf/mac.properties
+++ b/test/failure_handler/src/share/conf/mac.properties
@@ -64,7 +64,7 @@
 native.core.app=bash
 native.core.delimiter=\0
 native.core.args=-c\0gcore -o ./core.%p %p || \
-  (DevToolsSecurity --status | grep -q enabled && lldb -o 'attach %p' -o 
'process save-core core.%p' -o 'detach' -o 'quit')
+  (DevToolsSecurity --status | grep -q enabled && lldb --batch -o 'attach %p' 
-o 'process save-core core.%p' -o 'detach' -o 'quit')
 native.core.params.timeout=360
 

 # environment info to gather