by

Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
  • Jul 22 19:46
    apthorpe commented #234
  • Jun 30 17:02
    LeandreBl commented #351
  • Jun 30 17:02
    LeandreBl commented #351
  • Jun 30 10:13
    Snaipe commented #351
  • Jun 18 10:13
    abkarcher closed #354
  • Jun 18 10:13
    abkarcher commented #354
  • Jun 18 10:03
    daveabiy opened #357
  • Jun 18 09:57
    Snaipe commented #354
  • Jun 18 09:52
    daveabiy commented #354
  • Jun 18 09:50
    daveabiy commented #354
  • Jun 17 18:26
    arv-sajeev closed #355
  • Jun 17 18:26
    arv-sajeev commented #355
  • Jun 17 16:58
    Snaipe commented #355
  • Jun 17 16:54
    LeandreBl commented #351
  • Jun 17 16:50
    Snaipe commented #354
  • Jun 17 16:48
    Snaipe commented #356
  • Jun 17 16:44
    Snaipe commented #351
  • Jun 13 19:55
    risaldar opened #356
  • Jun 11 14:27
    arv-sajeev opened #355
  • Jun 09 19:59
    abkarcher opened #354
Ben Turrubiates
@bturrubiates
well they shouldn’t fail, i put that stuff in setup/teardown because it’s boilerplate that a whole suite will share. but sometimes it’s useful to be able to error if something in setup/teardown fails. i think it makes sense for abort to be the most obvious choice
yeah, sounds good to me. they shouldn’t fail, if they did then something has gone wrong
Franklin Mathieu
@Snaipe
right. downright exiting for these conditions makes the most sense because you're not explicitely testing that failure
Ben Turrubiates
@bturrubiates
what is the —debug option supposed to do if TYPE is not provided?
the -h output seems to indicate that it’s optional
Franklin Mathieu
@Snaipe
@bturrubiates it chooses a debugging server appropriately depending on the compiler used
gcc/icc make it use gdbserver, clang makes it use lldb-server
Ben Turrubiates
@bturrubiates
Oh, that makes sense. The system I’m working on has clang but not lldb. So I’m getting something like:
bturrubi at blade11 :: ./src/usnic-av-tests -j1 --debug
[----] Criterion v2.3.0-rc1
[====] Running 2 tests from bind_ep:
criterion: Could not spawn test instance: No such file or directory
[1]    23360 abort      ./src/usnic-av-tests -j1 --debug
Franklin Mathieu
@Snaipe
Ah, I thought I made the "No such file or directory" message a bit clearer, but I must've forgot
It should definitely print that the debugging server could not be found
Ben Turrubiates
@bturrubiates
Cool, I don’t think lldb-server works on Linux yet
Franklin Mathieu
@Snaipe
I'm on archlinux, and it works quite well on my end
Ben Turrubiates
@bturrubiates

Oh, weird. I was going off of this paragraph:

LLDB is improving on Linux. While the debugserver has not been ported (to enable remote debugging) Linux is nearing feature completeness with Darwin to debug x86_64 programs, and is partially working with i386 programs. ARM architectures on Linux are untested. For more details, see the Features by OS section below.

Found here: http://lldb.llvm.org/status.html

Franklin Mathieu
@Snaipe
It's probably bleeding edge, as Arch is doing rolling releases
I did not realize that the debugging server wasn't quite ready yet
perhaps it would be better to fallback to gdbserver if lldb-server isn't there
Ben Turrubiates
@bturrubiates
Yeah probably. I used to use Arch, having access to the most up-to-date packages was really nice.
Also, has Criterion always created *.sock files in the tests working directory? Or is that new?
Franklin Mathieu
@Snaipe
it's a side effect of nanomsg, so it's new
Ben Turrubiates
@bturrubiates
Whenever I get that abort due to lldb-server not being found, I also get left with a criterion_$pid.sock
Franklin Mathieu
@Snaipe
there's a pull request pending to put them in /tmp
Ben Turrubiates
@bturrubiates
oh neat. what is nanomsg used for? IPC?
Franklin Mathieu
@Snaipe
on 2.2.x and earlier criterion used pipe() to communicate with the tests, but it caused problems when the pipe buffer overflowed
with nanomsg, the library uses a unix socket for that
Ben Turrubiates
@bturrubiates
is nanomsg in active development right now?
i remember reading something a while ago about nanomsg being a dead project.
Franklin Mathieu
@Snaipe
Yes. It had a bit of a "dead" period near january because of internal disagreements and the maintainer stepping down
but he stepped up again about 3 months ago iirc
Ben Turrubiates
@bturrubiates
oh, so they found a new maintainer?
oh, that’s good.
Franklin Mathieu
@Snaipe
Well we expected someone to step up, but no one did and the project was considered "dead"
I was considering changing for something else at that time, but surprisingly there wasn't any good fit
ZeroMQ is mainly C++ and I'd like the project to remain C-only (plus it wasn't fork-safe, whereas I made a patch for nanomsg to make it fork-safe)
I have a bit more liberty with regards to switching libraries now though, as the new sandbox code calls exec() and doesn't require fork safety
Ben Turrubiates
@bturrubiates
when you say sandbox are you referring to boxfort?
Franklin Mathieu
@Snaipe
yes
Ben Turrubiates
@bturrubiates
oh cool, i saw that but haven’t looked very much into it. looks interesting though
Franklin Mathieu
@Snaipe
BoxFort was designed to completely rewrite the sandboxing code of criterion (which consisted of fork() on unices and a reimplementation of fork() on windows)
because it was a real hassle to maintain
BoxFort, on the other hand, provides a solid API for creating sandboxes with copy-on-write data sharing
so not only it is safer & more maintainable, it's also quite fast
Ben Turrubiates
@bturrubiates
oh nice, i’ll take a better look sometime. a while ago i tried looking into mimic, but then realized that a lot of the functions i wanted to mock were static inline
Franklin Mathieu
@Snaipe
ah, yes, that's a shame. I'd like to be able to mock static functions in the future by looking up non-dynamic symbols and patching them, but I'm a bit reluctant as this feature would probably be ELF-only
It's a complete shame that MSVC doesn't export a symbol table for its executables
Ben Turrubiates
@bturrubiates
i have very little experience developing on Windows, but i’ve seen a lot of the changes being made to one of the projects i contribute to as they port it to Windows and it looks frustrating
sometimes you don’t realize how many features are GCC extensions
(by very little i meant none)
Franklin Mathieu
@Snaipe
Maintaining API compatibility with MSVC is quite hard on that aspect, yes
I'm still wondering why people aren't using clang-cl these days
it would solve all of these problems