the code was like this,
tree->Draw("be>>h1(500,-100,10000-100)","cond==2&&bz==1&&dtime<91*5&&lea0<1000");
tree->Draw("be>>h2(500,-100,10000-100)","cond==2&&bz==1&&dtime>5000-91*5&&lea0<1000");
h1->Add(h2,-1);
h1->Draw();
it worked well. However, when I continue type following code in root,
tree->Draw("be>>h1(500,-100,10000-100)","cond==2&&bz==2&&dtime<91*5&&lea0<1000");
tree->Draw("be>>h2(500,-100,10000-100)","cond==2&&bz==2&&dtime>5000-91*5&&lea0<1000");
h1->Add(h2,-1);
h1->Draw();
it crashed in macOS 10.15(root 6.20.00,6.20.04,6.22.*), but worked well in archLinux(root 6.20.00).
Actually, it crashed with this line h1->Add(h2,-1)
.
Error code are listed here.
root [7] h1->Add(h2,-1)
*** Break *** segmentation violation
[/usr/lib/system/libsystem_platform.dylib] _sigtramp (no debug info)
[<unknown binary>] (no debug info)
[/Users/yfs/root/lib/libCling.6.20.00.so] cling::IncrementalExecutor::executeWrapper(llvm::StringRef, cling::Value*) const (no debug info)
[/Users/yfs/root/lib/libCling.6.20.00.so] cling::Interpreter::RunFunction(clang::FunctionDecl const*, cling::Value*) (no debug info)
[/Users/yfs/root/lib/libCling.6.20.00.so] cling::Interpreter::EvaluateInternal(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, cling::CompilationOptions, cling::Value*, cling::Transaction**, unsigned long) (no debug info)
[/Users/yfs/root/lib/libCling.6.20.00.so] cling::Interpreter::process(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, cling::Value*, cling::Transaction**, bool) (no debug info)
[/Users/yfs/root/lib/libCling.6.20.00.so] cling::MetaProcessor::process(llvm::StringRef, cling::Interpreter::CompilationResult&, cling::Value*, bool) (no debug info)
[/Users/yfs/root/lib/libCling.6.20.00.so] HandleInterpreterException(cling::MetaProcessor*, char const*, cling::Interpreter::CompilationResult&, cling::Value*) (no debug info)
[/Users/yfs/root/lib/libCling.6.20.00.so] TCling::ProcessLine(char const*, TInterpreter::EErrorCode*) (no debug info)
[/Users/yfs/root/lib/libRint.6.20.00.so] TRint::ProcessLineNr(char const*, char const*, int*) (no debug info)
[/Users/yfs/root/lib/libRint.6.20.00.so] TRint::HandleTermInput() (no debug info)
[/Users/yfs/root/lib/libCore.6.20.00.so] TUnixSystem::CheckDescriptors() (no debug info)
[/Users/yfs/root/lib/libCore.6.20.00.so] TMacOSXSystem::DispatchOneEvent(bool) (no debug info)
[/Users/yfs/root/lib/libCore.6.20.00.so] TSystem::InnerLoop() (no debug info)
[/Users/yfs/root/lib/libCore.6.20.00.so] TSystem::Run() (no debug info)
[/Users/yfs/root/lib/libCore.6.20.00.so] TApplication::Run(bool) (no debug info)
[/Users/yfs/root/lib/libRint.6.20.00.so] TRint::Run(bool) (no debug info)
[/Users/yfs/root/bin/root.exe] main (no debug info)
[/usr/lib/system/libdyld.dylib] start (no debug info)
Root >
When I rename (h1,h2) to (h3,h4), of course, everything is fine. But, but, the feel is not very good, especially the work need to be repeated a lot of times.
Maybe it suffers from the differences of platform(macOS and linux), but I don’t know how to fix it.
HELP!
ROOT Version: 6.20*,6.22*
Platform: macOS(10.15) failed, archLinux worked
Compiler: clang,gcc