nhaliday + hacker   43

unix - How can I profile C++ code running on Linux? - Stack Overflow
If your goal is to use a profiler, use one of the suggested ones.

However, if you're in a hurry and you can manually interrupt your program under the debugger while it's being subjectively slow, there's a simple way to find performance problems.

Just halt it several times, and each time look at the call stack. If there is some code that is wasting some percentage of the time, 20% or 50% or whatever, that is the probability that you will catch it in the act on each sample. So that is roughly the percentage of samples on which you will see it. There is no educated guesswork required. If you do have a guess as to what the problem is, this will prove or disprove it.

You may have multiple performance problems of different sizes. If you clean out any one of them, the remaining ones will take a larger percentage, and be easier to spot, on subsequent passes. This magnification effect, when compounded over multiple problems, can lead to truly massive speedup factors.

Caveat: Programmers tend to be skeptical of this technique unless they've used it themselves. They will say that profilers give you this information, but that is only true if they sample the entire call stack, and then let you examine a random set of samples. (The summaries are where the insight is lost.) Call graphs don't give you the same information, because

they don't summarize at the instruction level, and
they give confusing summaries in the presence of recursion.
They will also say it only works on toy programs, when actually it works on any program, and it seems to work better on bigger programs, because they tend to have more problems to find. They will say it sometimes finds things that aren't problems, but that is only true if you see something once. If you see a problem on more than one sample, it is real.
q-n-a  stackex  programming  engineering  performance  devtools  tools  advice  checklists  hacker  nitty-gritty  tricks  lol 
18 days ago by nhaliday
Complexity no Bar to AI - Gwern.net
Critics of AI risk suggest diminishing returns to computing (formalized asymptotically) means AI will be weak; this argument relies on a large number of questionable premises and ignoring additional resources, constant factors, and nonlinear returns to small intelligence advantages, and is highly unlikely. (computer science, transhumanism, AI, R)
created: 1 June 2014; modified: 01 Feb 2018; status: finished; confidence: likely; importance: 10
ratty  gwern  analysis  faq  ai  risk  speedometer  intelligence  futurism  cs  computation  complexity  tcs  linear-algebra  nonlinearity  convexity-curvature  average-case  adversarial  article  time-complexity  singularity  iteration-recursion  magnitude  multiplicative  lower-bounds  no-go  performance  hardware  humanity  psychology  cog-psych  psychometrics  iq  distribution  moments  complement-substitute  hanson  ems  enhancement  parable  detail-architecture  universalism-particularism  neuro  ai-control  environment  climate-change  threat-modeling  security  theory-practice  hacker  academia  realness  crypto  rigorous-crypto  usa  government 
april 2018 by nhaliday
National Defense Strategy of the United States of America
National Defense Strategy released with clear priority: Stay ahead of Russia and China: https://www.defensenews.com/breaking-news/2018/01/19/national-defense-strategy-released-with-clear-priority-stay-ahead-of-russia-and-china/

A saner allocation of US 'defense' funds would be something like 10% nuclear trident, 10% border patrol, & spend the rest innoculating against cyber & biological attacks.
and since the latter 2 are hopeless, just refund 80% of the defense budget.
Monopoly on force at sea is arguably worthwhile.
Given the value of the US market to any would-be adversary, id be willing to roll the dice & let it ride.
subs are part of the triad, surface ships are sitting ducks this day and age
But nobody does sink them, precisely because of the monopoly on force. It's a path-dependent equilibirum where (for now) no other actor can reap the benefits of destabilizing the monopoly, and we're probably drastically underestimating the ramifications if/when it goes away.
can lethal autonomous weapon systems get some
pdf  white-paper  org:gov  usa  government  trump  policy  nascent-state  foreign-policy  realpolitik  authoritarianism  china  asia  russia  antidemos  military  defense  world  values  enlightenment-renaissance-restoration-reformation  democracy  chart  politics  current-events  sulla  nuclear  arms  deterrence  strategy  technology  sky  oceans  korea  communism  innovation  india  europe  EU  MENA  multi  org:foreign  war  great-powers  thucydides  competition  twitter  social  discussion  backup  gnon  🐸  markets  trade  nationalism-globalism  equilibrium  game-theory  tactics  top-n  hi-order-bits  security  hacker  biotech  terrorism  disease  parasites-microbiome  migration  walls  internet 
january 2018 by nhaliday
The Membrane – spottedtoad
All of which is to say that the Internet, which shares many qualities in common with an assemblage of living things except for those clear boundaries and defenses, might well not trend toward increased usability or easier exchange of information over the longer term, even if that is what we have experienced heretofore. The history of evolution is every bit as much a history of parasitism and counterparasitism as it is any kind of story of upward movement toward greater complexity or order. There is no reason to think that we (and still less national or political entities) will necessarily experience technology as a means of enablement and Cool Stuff We Can Do rather than a perpetual set of defenses against scammers of our money and attention. There’s the respect that makes Fake News the news that matters forever more.

THE MADCOM FUTURE: http://www.atlanticcouncil.org/images/publications/The_MADCOM_Future_RW_0926.pdf

ai robocalls/phonetrees/Indian Ocean call centers~biologicalization of corporations thru automation&global com tech

fly-by-night scams double mitotically,covered by outer membrane slime&peptidoglycan

trillion $ corps w/nonspecific skin/neutrophils/specific B/T cells against YOU
ratty  unaffiliated  contrarianism  walls  internet  hacker  risk  futurism  speculation  wonkish  chart  red-queen  parasites-microbiome  analogy  prediction  unintended-consequences  security  open-closed  multi  pdf  white-paper  propaganda  ai  offense-defense  ecology  cybernetics  pessimism  twitter  social  discussion  backup  bio  automation  cooperate-defect  coordination  attention  crypto  money  corporation  accelerationism  threat-modeling  alignment 
december 2016 by nhaliday
Colin Percivel's homepage
interesting links to Hacker News highlights
people  security  engineering  programming  links  blog  stream  hn  hacker  🖥  techtariat 
october 2016 by nhaliday
Home-Built STM | Dan Berard
diy scanning tunneling microscope
diy  guide  hacker  maker  dirty-hands 
june 2016 by nhaliday

bundles : engframehackertechie

related tags

80000-hours  academia  accelerationism  acm  acmtariat  adversarial  advice  ai  ai-control  algorithms  alignment  allodium  altruism  analogy  analysis  announcement  anonymity  anthropology  antidemos  arms  art  article  asia  attention  audio  authoritarianism  automation  average-case  backup  bangbang  beauty  bio  biohacking  biotech  bitcoin  blog  books  bostrom  california  career  carmack  chart  checklists  china  civil-liberty  civilization  classic  clever-rats  climate-change  cocktail  cog-psych  comics  commentary  communism  community  competition  complement-substitute  complexity  computation  contrarianism  convexity-curvature  cool  cooperate-defect  coordination  core-rats  corporation  cracker-econ  critique  crypto  crypto-anarchy  cryptocurrency  cs  culture  current-events  cybernetics  data-science  database  death  debate  decentralized  decision-making  defense  definition  degrees-of-freedom  democracy  dennett  detail-architecture  deterrence  devtools  dirty-hands  discussion  disease  distribution  diy  documentary  drama  ecology  economics  econotariat  eden-heaven  effective-altruism  elegance  embedded  embodied  ems  engineering  enhancement  enlightenment-renaissance-restoration-reformation  environment  equilibrium  essay  ethics  EU  europe  expert-experience  explanation  faq  film  flux-stasis  foreign-policy  formal-values  frontier  futurism  game-theory  games  gnon  gnxp  government  graphics  gray-econ  great-powers  grugq  guide  gwern  hacker  hanson  hardware  health  hi-order-bits  history  hmm  hn  hsu  human-capital  humanity  ideas  ideology  idk  illusion  impetus  india  info-dynamics  infographic  init  innovation  intel  intelligence  internet  intricacy  iq  iteration-recursion  korea  labor  law  len:long  lens  lesswrong  letters  leviathan  linear-algebra  liner-notes  links  list  local-global  lol  lower-bounds  machine-learning  magnitude  maker  marginal  markets  math  media  MENA  mental-math  meta:war  migration  military  minimum-viable  mit  moloch  moments  money  mostly-modern  multi  multiplicative  music  music-theory  nascent-state  nationalism-globalism  network-structure  networking  neuro  news  nibble  nitty-gritty  no-go  nonlinearity  nuclear  oceans  offense-defense  open-closed  openai  opsec  org:biz  org:bleg  org:data  org:foreign  org:gov  org:lite  org:mag  org:mat  org:med  org:popup  org:sci  organization  oss  papers  parable  parasites-microbiome  parsimony  pdf  people  performance  pessimism  philosophy  pic  planning  play  plots  policy  polisci  politics  postmortem  postrat  power  pragmatic  prediction  prepping  preprint  presentation  privacy  profile  programming  project  propaganda  proposal  psychology  psychometrics  python  q-n-a  randy-ayndy  rationality  ratty  realness  realpolitik  red-queen  reference  reflection  regulation  research  review  rhetoric  rigorous-crypto  risk  roadmap  russia  science  scifi-fantasy  scitariat  search  security  SIGGRAPH  simulation  singularity  skunkworks  sky  smart-contracts  social  social-science  socs-and-mops  speculation  speedometer  spock  stackex  stats  stories  strategy  stream  street-fighting  subculture  sulla  summary  survival  sv  systems  tactics  tcs  tech  technology  techtariat  telos-atelos  terrorism  the-world-is-just-atoms  theory-practice  threat-modeling  thucydides  time-complexity  todo  tools  top-n  toys  trade  tradecraft  tricks  trivia  trump  tv  twitter  unaffiliated  unintended-consequences  universalism-particularism  urbit  usa  utopia-dystopia  values  vcs  vgr  video  virtu  visualization  volo-avolo  vulgar  walls  war  wealth  white-paper  wiki  woah  wonkish  world  yak-shaving  🐸  🖥  🤖 

Copy this bookmark: