Created attachment 1693 [details]
R source to reproduce the problem
I have noticed quadratic behavior of `[` when called for a vector where many elements don't have a corresponding entry in the table. The attached script illustrates the behavior, the results of a larger experiment set are on RPubs . Tested with R 3.1.2 and R-devel r67059.
The reason could be a nested loop that kicks in to postprocess mismatches .
The lookup process is non-interruptible, the only way out is to kill R entirely. This is especially surprising because a lookup operation is supposed to be cheap.
R version 3.1.2 (2014-10-31)
Platform: x86_64-pc-linux-gnu (64-bit)
 LC_CTYPE=en_US.UTF-8 LC_NUMERIC=C LC_TIME=en_US.UTF-8 LC_COLLATE=en_US.UTF-8
 LC_MONETARY=en_US.UTF-8 LC_MESSAGES=en_US.UTF-8 LC_PAPER=en_US.UTF-8 LC_NAME=C
 LC_ADDRESS=C LC_TELEPHONE=C LC_MEASUREMENT=en_US.UTF-8 LC_IDENTIFICATION=C
attached base packages:
 stats graphics grDevices utils datasets methods base
other attached packages:
 ggplot2_184.108.40.206 plyr_1.8.1
loaded via a namespace (and not attached):
 colorspace_1.2-4 digest_0.6.4 grid_3.1.2 gtable_0.1.2 MASS_7.3-35 munsell_0.4.2
 proto_0.3-10 Rcpp_0.11.3 reshape2_1.4 scales_0.2.4 stringr_0.6.2 tools_3.1.2